Part Number Hot Search : 
4HC57 60374KFK 1N974 BC849BT AAT11 03597 AKD7782 20ETTTS
Product Description
Full Text Search
 

To Download LPC47M15X Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  smsc ds ? LPC47M15X rev. 08/02/2001 lpc super i/o with hard ware monitoring block features 3.3 volt operation (sio block is 5 volt tolerant) lpc interface acpi 1.0 compliant fan control - fan speed control outputs (2) - fan tachometer inputs (2) programmable wake-up event interface pc98, pc99 compliant dual game port interface mpu-401 midi support general purpose input/output pins (37) isa plug-and-play compatible register set intelligent auto power management system management interrupt 2.88mb super i/o floppy disk controller - licensed cmos 765b floppy disk controller - software and register compatible with smsc's proprietary 82077aa compatible core - supports two floppy drives - configurable open drain/push-pull output drivers - supports vertical recording format - 16-byte data fifo - 100% ibm compatibility - detects all overrun and underrun conditions - sophisticated power control circuitry (pcc) including multiple powerdown modes for reduced power consumption - dma enable logic - data rate and drive control registers - 480 address, up to 15 irq and three dma options enhanced digital data separator - 2 mbps, 1 mbps, 500 kbps, 300 kbps, 250 kbps data rates - programmable precompensation modes keyboard controller - 8042 software compatible - 8 bit microcomputer - 2k bytes of program rom - 256 bytes of data ram - four open drain outputs dedicated for keyboard/mouse interface - asynchronous access to two data registers and one status register - supports interrupt and polling access - 8 bit counter timer - port 92 support - fast gate a20 and kreset outputs serial ports - two full function serial ports - high speed ns16c550a compatible uarts with send/receive 16-byte fifos - supports 230k and 460k baud programmable baud rate generator modem control circuitry - 480 address and 15 irq options infrared port - multiprotocol infrared interface - irda 1.0 compliant - sharp ask ir - 480 addresses, up to 15 irq multi-mode parallel port with chiprotect - standard mode ibm pc/xt pc/at, and ps/2 compatible bi-directional parallel port - enhanced parallel port (epp) compatible - epp 1.7 and epp 1.9 (ieee 1284 compliant) - ieee 1284 compliant enhanced capabilities port (ecp) - chiprotect circuitry for protection - 960 address, up to 15 irq and three dma options lpc interface - multiplexed command, address and data bus - serial irq interface compatible with serialized irq support for pci systems - pme interface hardware monitor - monitor power supplies (+2.5v, +3.3v, +5v, +12v, +1.8v, +1.5v, vccp (processor voltage), and hvcc or hvsb) - remote thermal diode sensing for two external temperature measurements - internal ambient temperature measurement - limit comparison of all monitored values - system management bus (smbus) interface - ntherm pin for out-of-limit temperature or voltage indication - nreset pin for generating 20msec low reset pulse - configurable offset for internal or external temperature channels. 128 pin qfp package, 3.9mm footprint LPC47M15X preliminary
smsc ds ? LPC47M15X page 2 rev. 08/02/2001 80 arkay drive hauppauge, ny 11788 (631) 435-6000 fax (631) 273-3123 copyright ? smsc 2004. all rights reserved. circuit diagrams and other information rela ting to smsc products are included as a m eans of illustrating typical applications. consequently, complete information sufficient for c onstruction purposes is not necessarily given. although the information has been checked and is bel ieved to be accurate, no responsibility is assumed for inaccuracies. smsc reserves the right to make changes to specifications and product descriptions at any time without notice. contact your local smsc sales office to obtain the la test specifications before placi ng your product order. the provisi on of this information does not convey to the purchaser of the described semiconductor devic es any licenses under any patent ri ghts or other intellectual p roperty rights of smsc or others. all sales are expressly conditional on your agreement to the terms and conditions of the most recently dated version of smsc's standard terms of sale agreement dated before the date of your order (t he "terms of sale agreement"). the product may contain design def ects or errors known as anomalies which may caus e the product's functions to deviate from publis hed specifications. anomaly sheets are availab le upon request. smsc products are not designed, intended, authorized or warranted for use in any life support or other application where produc t failure could cause or contribute to personal injury or severe property damage. any and all such uses without prior written approval of an officer of smsc and further testing and/or modification will be fully at t he risk of the customer. copies of this do cument or other smsc literature, as wel l as the terms of sale agreement, may be obtained by visiting smsc?s website at http://www .smsc.com. smsc is a registered trademark of standard micros ystems corporation (?smsc?). product names and company names are the trademarks of their respective holders. smsc disclaims and excludes any and a ll warranties, including without limitation any and all implied warranties of merchantability, fitn ess for a particular purpose, title, and against infringement and the like, and any and all warranties arising from any course of dealing or usage of trade. in no event shall smsc be liable for an y direct, incidental , indirect, special, punitive, or consequential damages; or for lost data, profits, savings or revenues of any kind; regardless of th e form of action, whether based on contract; tort; negligence of smsc or others; strict li ability; breach of warranty; or otherwise; whether or not any remedy of buyer is held to have failed of its essential purpose, and whet her or not smsc has been advised of the possibility of such damages.
smsc ds ? LPC47M15X page 3 rev. 08/02/2001 general description the LPC47M15X* is a pc99/200 1 compliant advanced i/o controller with an lpc interface and hardware monitoring capabilities. the design is compatible with a family of smsc advanced i/o cont rollers, the lp c47m13x and lpc47m14x. each device in the family is pin compatible within the i/o secti on and offers enhanced functionality. the lpc47m13x is the base part offering co mplete i/o functionality, lpc47m14x includes a 4 port usb hub as well as i/o, and the LPC47M15X contains ha rdware monitoring capability. the LPC47M15X?s hardware monitoring capability includes voltage and temperature monitoring with the ability to alert the system of out-of-limit conditions. t here are 7 analog inputs for monitoring external voltages of +1.5v, +1.8v, +2.5v, +3.3v, +5v, +12v and vccp (core processor voltage) , as well as internal monitoring of the devices own hvcc or hvsb. the LPC47M15X includ es support for monitoring tw o external temperatures via thermal diode inputs and an internal sensor for measuring ambient temperature. t he ntherm pin is implemented to indicate out-of-limit temperature and voltage conditions. the block has an abi lity to output 20ms low pulse via nreset pin. the hardware monitoring block of the LPC47M15X is acce ssible via the system management bus (smbus). the LPC47M15X incorporates complete legacy super i/o functio nality including an 8042 based keyboard and mouse controller, an ieee 1284, epp, and ecp co mpatible parallel port, two serial ports that are 16c550a uart compatible, two irda 1.0 infrared ports, and a floppy disk controller with smsc's true cmos 765b core and enhanced digital data separator, the true cmos 765b core pr ovides 100% compatibility with ibm pc/xt and pc/at architectures and is software and register compatible wi th smsc's proprietary 82077aa core. system related functionality, which offers flexibility to the system desig ner, includes an mpu-401 midi interface, (37) general purpose i/o control functions, control of two led?s, a game port interface supporting two joysticks, and fan control using fan tachometer inputs and puls e width modulator, (pwm), outputs. the LPC47M15X is acpi 1.0 compatible and therefore supports multiple lo w power-down modes. it incorporates sophisticated power control circuitry (pcc) which includes support for keyboard and mouse wake-up events. the LPC47M15X supports the isa plug- and-play standard register set (v ersion 1.0a). the i/o address, dma channel and hardware irq of each logical device in the LPC47M15X may be reprogrammed through the internal configuration r egisters. there are upto 480 (960 - parallel port) i/o address location options, a serialized irq interface, and three dma channels. the LPC47M15X does not require any external filter compo nents and is therefore easy to use and offers lower system costs and reduced board area. * the ?x? in the part number is a designator that changes depending upon the particular bios used inside the specific chip. ordering information part# package keyboard bios lpc47m152-nc 128 pin qfp ami lpc47m157-nc 128 pin qfp phoenix 42i
smsc ds ? LPC47M15X page 4 rev. 08/02/2001 table of contents 1. pin layout .................................................................................................................. ........................ 9 2. pin conf iguration ........................................................................................................... ............. 10 3. description of pin fu nctions ................................................................................................ .. 11 3.1 b uffer name d escriptions ......................................................................................................... 19 3.2 p ins t hat r equire e xternal p ullup r esistors .......................................................................... 20 3.2.1 super i/o pins ........................................................................................................... .............................20 3.2.2 hardware moni toring blo ck pins........................................................................................... ..................20 4. block diagram............................................................................................................... ................ 21 5. power func tionality ......................................................................................................... ......... 22 5.1 vcc/hvcc p ower ........................................................................................................................ 22 5.1.1 3 volt operation / 5 volt tolera nce ...................................................................................... .22 5.2 vref p in ............................................................................................................................... ........ 22 5.3 vtr s upport ............................................................................................................................... .. 22 5.3.1 trickle powe r function ality.............................................................................................. .......................22 5.4 32.768 k h z t rickle c lock i nput .................................................................................................. 24 5.5 i nternal pwrgoo d..................................................................................................................... 24 5.6 m aximum c urrent v alues ............................................................................................................. 24 5.6.1 super i/o func tions ...................................................................................................... ..........................24 5.6.2 hardware monito ring block functi ons ...................................................................................... ..............25 5.7 p ower m anagement e vents (pme/sci)....................................................................................... 25 6. functional description...................................................................................................... ....... 26 6.1 s uper i/o r egisters ..................................................................................................................... 26 6.2 h ost p rocessor i nterface (lpc) ............................................................................................... 26 6.3 lpc i nterface ............................................................................................................................... 27 6.3.1 lpc interface signal de finition.......................................................................................... .....................27 6.3.2 lpc cycles............................................................................................................... ..............................27 6.3.3 field de finitions ........................................................................................................ ..............................27 6.3.4 nlframe usage............................................................................................................ ........................27 6.3.5 i/o read and write c ycles ................................................................................................ .....................27 6.3.6 dma read an d write cycles ................................................................................................ ..................28 6.3.7 dma protoc ol ............................................................................................................. ............................28 6.3.8 power management......................................................................................................... .......................28 6.3.9 sync protocol ............................................................................................................ ...........................28 6.3.10 lpc transf ers ........................................................................................................... ...................29 6.4 floppy disk controller..................................................................................................... . 29 6.4.1 fdc inter nal regi sters ................................................................................................... ........................29 6.4.2 status regi ster e ncoding ................................................................................................. .........40 6.4.3 instru ction set.......................................................................................................... ...............................47 6.4.4 data tran sfer commands................................................................................................... .........53 6.4.5 direct support for two flo ppy drives .................................................................................64 6.4.6 fdc swap bi t ............................................................................................................. ............................64 6.5 serial po rt (uart) ......................................................................................................... ......... 64 6.6 infrared interface ......................................................................................................... ...... 76 6.7 mpu-401 midi uart.......................................................................................................... ........... 78 6.7.1 ov ervi ew................................................................................................................. ................................78 6.7.2 host interf ace ........................................................................................................... ..............................78 6.7.3 midi data port ........................................................................................................... .............................79 6.7.4.......................................................................................................................... ............................................79 6.7.5 stat us po rt.............................................................................................................. ................................79 6.7.6 mpu-401 comm and controller ............................................................................................... ...............81 6.7.7 midi uart ................................................................................................................ .............................81 6.7.8 mpu-401 confi guration re gisters .......................................................................................... ................82 6.8 paralle l po rt .............................................................................................................. ............ 82
smsc ds ? LPC47M15X page 5 rev. 08/02/2001 6.8.1 ibm xt/at compatible, bi -directional and epp modes ....................................................................... ..83 6.8.2 extended capabili ties parall el port...................................................................................... ...................88 6.9 power ma nagement........................................................................................................... .... 98 6.10 seria l irq................................................................................................................ .............. 101 6.11 8042 keyboard contro ller descri ption ................................................................. 104 6.11.1 keyboard interface...................................................................................................... ......................104 6.11.2 external keyboard and mouse interface ................................................................................... ........106 6.11.3 keyboard po wer management............................................................................................... ...........106 6.11.4 inte rrupts.............................................................................................................. .............................106 6.11.5 memory co nfigurat ions ................................................................................................... ..................106 6.11.6 register defini tions .................................................................................................... .......................106 6.11.7 external clock si gnal ................................................................................................... .....................107 6.11.8 default re set cond itions ................................................................................................ ..................107 6.11.9 keyboard and m ouse pme g eneratio n....................................................................................... ......111 6.12 general purpose i/o ....................................................................................................... . 112 6.12.1 gp io pins ............................................................................................................... ..........................112 6.12.2 descr iption ............................................................................................................. ...........................113 6.12.3 gpio contro l............................................................................................................ .........................114 6.12.4 gpio o peratio n .......................................................................................................... ......................115 6.12.5 gpio pme and sm i function ality .......................................................................................... ...........116 6.12.6 either edge triggered in terrupts ........................................................................................ ...............117 6.12.7 led func tionality ....................................................................................................... .......................117 6.13 system management interrupt (smi)......................................................................... 118 6.13.1 smi r egister s........................................................................................................... .........................118 6.14 pme support............................................................................................................... ......... 119 6.14.1 ?wake on specific key? option ........................................................................................... ...............120 6.15 fan speed contro l and moni toring .......................................................................... 121 6.15.1 fan spee d cont rol ....................................................................................................... .....................121 6.15.2 fan spee d monito ring.................................................................................................... ...................122 6.16 securit y feat ure.......................................................................................................... .... 124 6.16.1 gpio device disable register control .................................................................................... .........124 6.16.2 device di sable r egist er................................................................................................. ...................125 6.17 game po rt logic ........................................................................................................... ..... 125 6.17.1 power cont rol regi ster .................................................................................................. ...................127 6.17.2 vref pin ................................................................................................................ ..........................127 6.18 h ardware m onitoring i nterface ........................................................................................... 128 6.18.1 hardware monitoring in terface signal defini tion ......................................................................... ......128 6.18.2 smbus interf ace......................................................................................................... .......................129 6.18.2.1 smbus sl ave interface ................................................................................................. ................................ 129 6.18.3 hardware mo nitoring block ............................................................................................... ................131 6.18.3.1 input monito ring...................................................................................................... ..................................... 131 6.18.3.2 resetting the hard ware monito ring block ............................................................................... .................... 132 6.18.3.3 reset out pin ......................................................................................................... ....................................... 132 6.18.3.4 monito ring modes ...................................................................................................... .................................. 132 6.18.3.5 interrupt st atus registers............................................................................................ .................................. 133 6.18.3.6 low po wer modes ....................................................................................................... ................................. 133 6.18.3.7 analog volt age measurement ............................................................................................ .......................... 134 6.18.3.8 vo ltage id ............................................................................................................ ........................................ 134 6.18.3.9 temperatur e measurement ............................................................................................... ............................ 134 6.18.3.10 thermal / vo ltage interrupt pin...................................................................................... ............................ 135 6.18.3.11 i nput sa fety ......................................................................................................... ....................................... 136 6.18.3.12 layout consider ations ................................................................................................ ................................ 136 7. runtime registers ........................................................................................................... .......... 138 8. configuration ............................................................................................................... .............. 164 9. registers for hardware monitoring block ................................................................. 182 9.1 r egister s ummary ...................................................................................................................... 182 9.2 i nternal a ddress r egister ....................................................................................................... 182 9.3 v alue or l imit r egisters (15 h -3d h ) .......................................................................................... 183 9.3.1.1 regist ers 3eh-4fh...................................................................................................... ................................... 184
smsc ds ? LPC47M15X page 6 rev. 08/02/2001 10. operational description.................................................................................................... . 188 10.1 m aximum g uaranteed r atings ................................................................................................ 188 10.1.1 super i/o secti on (pins 1 to 100)....................................................................................... ................188 10.1.2 hardware monitoring block (pins 101 to 128) ............................................................................. ......188 10.2 h ardware m onitoring b lock s pecifications ........................................................................ 188 10.2.1 key spec ificat ions...................................................................................................... .......................188 10.2.2 supply curre nt .......................................................................................................... ........................188 10.2.3 operating temperature................................................................................................... ..................188 10.2.4 operating voltage ra tings ............................................................................................... .................188 10.3 dc e lectrical c haracteristics ............................................................................................. 189 11. timing diagrams ............................................................................................................ ........... 195 12. packag e outline............................................................................................................ .......... 217 13. appendix a ? therma l diode para meters ...................................................................... 218 14. appendix b ? adc vo ltage conv ersion ........................................................................... 219 15. appendix c - test mode ..................................................................................................... ..... 220 15.1 s uper i/o b lock ....................................................................................................................... 220 15.1.1 board test mode......................................................................................................... ......................220 15.2 h ardware m onitoring b lock ................................................................................................. 222 15.2.1 board test mode......................................................................................................... ......................222 15.2.2 xnor-chain test mode .................................................................................................... ...............222 16. reference documents ........................................................................................................ .. 224 tables table 1 ? super i/o block a ddresse s .......................................................................................... ..............................26 table 2 ? status, data and control registers ................................................................................. ...........................30 table 3 ? internal 2 drive dec ode ? no rmal ................................................................................... ...........................33 table 4 ? internal 2 drive decode ? drives 0 and 1 sw apped................................................................... ................34 table 5 ? t ape select bits ................................................................................................... ......................................34 table 6 ? dr ive type id ...................................................................................................... .......................................35 table 7 ? precom pensation delays ............................................................................................. ..............................35 table 8 ? data ra tes ......................................................................................................... ........................................36 table 9 ? drv den mapp ing ..................................................................................................... ................................36 table 10 ? default pr ecompensati on dela ys .................................................................................... .........................37 table 11 ? fifo service delay ................................................................................................ ..................................38 table 12 ? stat us regist er 0................................................................................................. .....................................41 table 13 ? stat us regist er 1................................................................................................. .....................................41 table 14 ? stat us regist er 2................................................................................................. .....................................41 table 15 ? stat us regist er 3................................................................................................. .....................................42 table 16 ? description of command symbols .................................................................................... .......................45 table 17 ? in structi on set ................................................................................................... .......................................47 table 18 ? se ctor si zes ...................................................................................................... .......................................53 table 19 ? effect s of mt and n bi ts.......................................................................................... .................................54 table 20 ? skip bit vs read data command ..................................................................................... ........................54 table 21 ? skip bit vs. read deleted da ta command............................................................................ ...................55 table 22 ? resu lt phase table ................................................................................................ ..................................55 table 23 ? verify comm and result ph ase t able ................................................................................. .....................57 table 24 ? typical values for formatti ng..................................................................................... ..............................58 table 25 ? interr upt identif ication.......................................................................................... .....................................60 table 26 ? drive co ntrol delays (ms) ......................................................................................... ...............................61 table 27 ? effects of wgate and gap bits..................................................................................... .........................63 table 28 ? addressi ng the seri al port........................................................................................ ................................65 table 29 ? interr upt contro l table ........................................................................................... ..................................67 table 30 ? baud ra tes ........................................................................................................ ......................................73 table 31 ? rese t function table .............................................................................................. .................................74
smsc ds ? LPC47M15X page 7 rev. 08/02/2001 table 32 ? register summary for an individual uart c hannel ................................................................... .............74 table 33 ? mpu-401 host interface regist ers.................................................................................. .........................79 table 34 ? mi di data port .................................................................................................... .....................................79 table 35 ? mpu- 401 status port ............................................................................................... ................................79 table 36 ? midi receive buffer empty st atus bit.............................................................................. ........................79 table 37 ? midi trans mit busy st atus bit ..................................................................................... ............................80 table 38 ? mpu- 401 comm and po rt .............................................................................................. ...........................80 table 39 ? paralle l port co nnector ........................................................................................... .................................83 table 40 ? epp pin descr iptions .............................................................................................. .................................87 table 41 ? ecp pin descr iptions .............................................................................................. .................................89 table 42 ? ecp re gister de finiti ons.......................................................................................... ................................90 table 43 ? m ode descrip tions................................................................................................. ...................................90 table 44a ? extende d control regist er ........................................................................................ .............................94 table 45 ? channel/data comma nds supported in ecp mode ....................................................................... ..........96 table 46 ? pc/at and ps/ 2 available registers ................................................................................ .......................99 table 47 ? state of system pins in auto powerdown ............................................................................ ....................99 table 48 ? state of floppy disk dr ive interface pins in powerdown............................................................ ............100 table 49 ? i/ o address map ................................................................................................... .................................104 table 50 ? host interfac e fl ags .............................................................................................. .................................105 table 51 ? st atus re gister................................................................................................... ....................................106 table 52 ? resets ............................................................................................................ ........................................107 table 53 ? general purp ose i/o port assignm ents .............................................................................. ...................113 table 54 ? gpio conf iguration summary........................................................................................ ........................115 table 55 ? gpio r ead/write b ehavio r .......................................................................................... ..........................115 table 56 ? differ ent modes for fan........................................................................................... ...............................121 table 57 ? smbus write byte protocol .................................................................................................... ................129 table 58 ? smbus read byte pr otoc ol..................................................................................................... ...............130 table 59 ? smbus send by te prot ocol ..................................................................................................... ...............130 table 60 ? smbus receive byte protocol .................................................................................................. .............130 table 61 ? modified smbus receive byte protocol respons e to ar a.................................................................... 131 table 62 ? runtime r egister blo ck summary.................................................................................... ......................138 table 63 ? runtime regi ster block descrip tion ................................................................................ .......................141 table 64 ? LPC47M15X conf iguration regi sters summary......................................................................... ............166 table 65 ? chip level regi sters .............................................................................................. ................................168 table 66 ? logical device r egisters.......................................................................................... ..............................171 table 67 ? i/o base address conf iguration register description............................................................... .............173 table 68 ? interrupt select c onfiguration regist er descr iption ............................................................... ................174 table 69 ? dma channel select co nfiguration regist er descr iption............................................................. ..........175 table 70 ? floppy disk controller, logical device 0 [logical devi ce number = 0x00] ........................................... .176 table 71 ? parallel port, logical device 3 [logical device number = 0x03].................................................... ........177 table 72 ? serial port 1, logical de vice 4 [logical device number = 0x04].................................................... ........178 table 73 ? serial port 2, logical de vice 5 [logical device number = 0x05].................................................... ........179 table 74 ? kybd, logical device 7 [l ogical device nu mber = 0x07] ............................................................. ........180 table 75 ? pme, logical device a [logical device nu mber = 0x0a].............................................................. .........181 table 76 ? mpu-401 [logical device num ber = 0x 0b] ............................................................................ ................181 table 77 ? thermal diode para meters ............................................................................................ ..........................218 table 78 ? analog-to-digital conversions fo r hardware moni toring bl ock.................................................................21 9 figures figure 1 ? lpc47m 15x block diagram.......................................................................................... .................21 figure 2 ? mpu-40 1 midi in terface............................................................................................ ......................78 figure 3 ? mp u-401 in terrupt ................................................................................................. .........................80 figure 4 ? midi data by te exam ple ........................................................................................................ ..........82 figure 5 ? keyboard latch .................................................................................................... ........................110 figure 6 ? mouse la tch....................................................................................................... ............................110 figure 7 ? gpio f unction illu stration........................................................................................ ..............115 figure 8 ? fan tachometer inpu t and cloc k source ............................................................................122 figure 9 ? conceptual block diagram of fan monitori ng l ogic .....................................................123 figure 10 ? suggested minimum trac k width and spacing ..................................................................136 figure 11 ? using a diode as a remote te mperature sensing elemen t .........................................137 figure 12 ? po wer-up timing .................................................................................................. .......................196 figure 13 ? in put clock timing ............................................................................................... ......................196
smsc ds ? LPC47M15X page 8 rev. 08/02/2001 figure 14 ? pc i clock timing................................................................................................. .........................197 figure 15 ? reset ti ming ..................................................................................................... ............................197 figure 16 ? ouput timing measure ment conditions, lpc sign als ................................................... 197 figure 17 ? input timing measure ment conditions, lpc sign als ..................................................... 198 figure 18 ? i/o write ........................................................................................................ .................................198 figure 19 ? i/o read......................................................................................................... ..................................198 figure 20 ? dma request assertion thro ugh nl drq........................................................................... 198 figure 21 ? dma wr ite (first byte) ........................................................................................... ...................198 figure 22 ? dma r ead (first byte)............................................................................................ ....................199 figure 23 ? floppy disk dri ve timing (at mode on ly) .......................................................................... .199 figure 24 ? epp 1.9 data or address wr ite cy cle .............................................................................. ...200 figure 25 ? epp 1.9 data or address r ead cycle ............................................................................... ...201 figure 26 ? epp 1.7 data or address wr ite cy cle .............................................................................. ...202 figure 27 ? epp 1.7 data or address r ead cycle ............................................................................... ...202 figure 28 ? paralle l port fifo timing ........................................................................................ ...............204 figure 29 ? ecp paralle l port forw ard timing ................................................................................. ...205 figure 30 ? ecp paral lel port r everse ti ming................................................................................. .....206 figure 31 ? irda receive timing.............................................................................................. ......................207 figure 32 ? irda transmit timing ............................................................................................. ....................208 figure 33 ? amplitude sh ift keyed ir re ceive ti ming .......................................................................... .209 figure 34 ? amplitude shif t keyed ir transm it timing ........................................................................2 10 figure 35 ? setu p and hold time.............................................................................................. ....................211 figure 36 ? ser ial port data ................................................................................................. .......................211 figure 37 ? joysti ck position signal ......................................................................................... ................212 figure 38 ? joys tick button signal ........................................................................................... ................212 figure 39 ? keyboard/mouse receive/send da ta timi ng ..................................................................... 213 figure 40 ? mi di data byte ................................................................................................... ...........................213 figure 41 ? fa n output timing ................................................................................................ ......................214 figure 42 ? fan tacho meter intput timing ..................................................................................... .........214 figure 43 ? le d output timing ................................................................................................ ......................215 figure 44 ? sm bus timing ....................................................................................................... ...........................216 figure 45 ? 128 pin qfp package outline, 3.9mm footprin t ................................................................217 figure 46 ? xnor-c hain test struct ure........................................................................................ ...........220
smsc ds ? LPC47M15X page 9 rev. 08/02/2001 1. pin layout 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 128 127 126 125 124 123 122 121 120 119 118 117 116 115 114 113 112 111 110 109 108 107 106 105 104 103 102 101 100 99 98 97 96 95 94 93 92 91 90 89 88 87 86 85 84 83 82 81 80 79 78 77 76 75 74 73 72 71 70 69 68 67 66 65 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 LPC47M15X 128 pin qfp gp17 /j2y avss gp20/p17 gp21/p16/nds1 gp22/p12/nmtr1 vref gp24/sysopt gp25/midi_in gp26/midi_out gp60/led1 gp61/led2 gp27/nio_smi gp30/fan_tach2 gp31/fan_tach1 vcc gp32/fan2 gp33/fan1 kdat kclk mdat mclk vss irrx2/gp34 irtx2/gp35 gp36/nkbdrst gp37/a20m gp40/drvden0 gp41/drvden1 nmtr0 ndskchg nds0 clki32 vss ndir nstep nwdata nwgate nhdsel nindex ntrk0 nwrtprt nrdata gp42/nio_pme vtr clocki lad0 lad1 lad2 lad3 nlframe nldrq npci_reset nlpcpd gp43/ddrc pci_clk ser_irq vss gp10 /j1b1 gp11 /j1b2 gp12 /j2b1 gp13 /j2b2 gp14 /j1x gp15 /j1y gp16 /j2x hvss hvss hvss hvss d1- d1+ hvcc hvcc +1.5v_in +1.8v_in vccp_in +2.5v_in +3.3v_in +5v_in d0+ d0-/xnor_in hvss hvcc 12v_in/vid4 vid3 vid2 vid1 vid0 a0/nreset/ntherm sclk sda hvcc hvss gp57/ndtr2 gp56/ncts2 gp55/nrts2 gp54/ndsr2 gp53/txd2 (irtx) gp52/rxd2 (irrx) gp51/ndcd2 vcc gp50/nri2 ndcd1 nri1 ndtr1 ncts1 nrts1 ndsr1 txd1 rxd1 nstrobe nalf nerror nack busy pe slct vss pd7 pd6 pd5 pd4 pd3 pd2 pd1 pd0 nslctin ninit vcc
smsc ds ? LPC47M15X page 10 rev. 08/02/2001 2. pin configuration pin # name pin # name pin # name pin # name 1 gp40/drvden0 33 gp11 /j1b2 65 vcc 97 gp54/ndsr2 2 gp41/drvden1 34 gp12 /j2b 1 66 ninit 98 gp55/nrts2 3 nmtr0 35 gp13 /j2b2 67 nslctin 99 gp56/ncts2 4 ndskchg 36 gp14 /j1x 68 pd0 100 gp57/ndtr2 5 nds0 37 gp15 /j1y 69 pd1 101 hvss 6 clki32 38 gp16 /j2x 70 pd2 102 hvcc 7 vss 39 gp17 /j2y 71 pd3 103 sda 8 ndir 40 avss 72 pd4 104 sclk 9 nstep 41 gp20/p17 73 pd5 105 a0/nreset/ ntherm/ xnor_out 10 nwdata 42 gp21/p16/nds1 74 pd6 106 vid0 11 nwgate 43 gp22/p12/nmtr1 75 pd7 107 vid1 12 nhdsel 44 vref 76 vss 108 vid2 13 nindex 45 gp24/sysopt 77 slct 109 vid3 14 ntrk0 46 gp25/midi_i n 78 pe 110 12v_in/vid4 15 nwrtprt 47 gp26/midi_out 79 busy 111 hvcc 16 nrdata 48 gp60/led1 80 nack 112 hvss 17 gp42/nio_pme 49 gp61/led2 81 nerror 113 d0-/xnor_in 18 vtr 50 gp27/nio_smi 82 nalf 114 d0+ 19 clocki 51 gp30/fan_tach 2 83 nstrobe 115 +5v_in 20 lad0 52 gp31/fan_tach 1 84 rxd1 116 +3.3v_in 21 lad1 53 vcc 85 txd1 117 +2.5v_in 22 lad2 54 gp32/fan2 86 ndsr1 118 v ccp _in 23 lad3 55 gp33/fan1 87 nrts1 119 +1.8v_in 24 nlframe 56 kdat 88 ncts1 120 +1.5v_in 25 nldrq 57 kclk 89 ndtr1 121 hvcc 26 npci_reset 58 mdat 90 nri1 122 hvcc 27 nlpcpd 59 mclk 91 ndcd1 123 d1+ 28 gp43/ddrc 60 vss 92 gp50/nri2 124 d1- 29 pci_clk 61 irrx2/gp34 93 vcc 125 hvss 30 ser_irq 62 irtx2/gp35 94 gp51/ndcd2 126 hvss 31 vss 63 gp36/nkbdrst 95 gp52/rxd2 (irrx) 127 hvss 32 gp10 /j1b1 64 gp37/a20m 96 gp53/txd2 (irtx) 128 hvss note: the chip is part of a family of lpc chips (lpc47m13x , lpc47m14x). the first 100 pins of these chips are pin compatible, which adds more flexibility for the board designer.
smsc ds ? LPC47M15X page 11 rev. 08/02/2001 3. description of pin functions qfp pin# name description buffer name pwr well notes power pins (10) 53, 65,93 vcc +3.3 volt supply voltage 1 18 vtr +3.3 volt standby supply voltage 2 44 vref reference voltage 7, 31, 60,76 vss ground 1 40 avss analog ground clocks (2) 6 clocki32 32.768khz trickle clock input is vtr 3 19 clocki 14.318mhz clock input is vcc processor/host lpc interface (10) 23:20 lad[3:0] active high lpc i/o used for multiplexed command, address and data bus. pci_io vcc 24 nlframe active low input indicates start of new cycle and termination of broken cycle. pci_i vcc 25 nldrq active low output used for encoded dma/bus master request for the lpc interface. pci_o vcc 26 npci_reset active low input used as lpc interface reset. pci_i vcc 27 nlpcpd active low input power down signal indicates that the LPC47M15X should prepare for power to be shut-off on the lpc interface. pci_i vcc 4 29 pci_clk pci clock input. pci_iclk vcc 30 ser_irq serial irq pin used with the pci_clk pin to transfer LPC47M15X interrupts to the host. pci_io vcc fan control (4) 51 gp30/ fan_tach2 general purpose i/o. gpio can be configured as an open-drain output. /fan tachometer 2 input io8 vcc 5 52 gp31/ fan_tach1 general purpose i/o. gpio can be configured as an open-drain output. /fan tachometer 1 input io8 vcc 5 54 gp32/ fan2 general purpose i/o /fan speed control 2 output both functions can be configured as open- drain output. io12 vcc 5, 6 55 gp33/ fan1 general purpose i/o /fan speed control 1 output both functions can be configured as open- drain output. io12 vcc 5, 6 fdd interface (14) 16 nrdata raw serial bit stream from the disk drive, low active. each falling edge represents a flux transition of the encoded data. is vcc
smsc ds ? LPC47M15X page 12 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 11 nwgate write gate output. this active low high current driver allows current to flow through the write head. it becomes active just prior to writing to the diskette. can be configured as an open-d rain output. o12 vcc 10 nwdata write disk data output. this active low high current driver provides the encoded data to the disk drive. each falling edge causes a flux transition on the media. can be configured as an open-drain output. o12 vcc 12 nhdsel head select output. this high current output selects the floppy disk side for reading or writing. a logic ?1? on this pin means side 0 will be accessed, while a logic ?0? means side 1 will be accessed. can be configured as an open-d rain output. o12 vcc 8 ndir step direction output. this high current low active output determines the direction of the head movement. a logic ?1? on this pin means outward motion, while a logic ?0? means inward motion. can be configured as an open-dra in output. o12 vcc 9 nstep step pulse output. this active low high current driver issues a low pulse for each track-to-track movement of the head. can be configured as an open-drain output. o12 vcc 4 ndskchg this input senses that the drive door is open or that the diskette has possibly been changed since the last drive selection. this input is invert ed and read via bit 7 of i/o address 3f7h. the ndskchg bit also depends upon the stat e of the force disk change bits in the force disk change register (see runtime registers section). is vcc 5 nds0 drive select 0 output. can be configured as an open-dra in output. o12 vcc 3 nmtr0 motor on 0 output. can be configured as an open-dra in output. o12 vcc 15 nwrtprt this active low schmitt trigger input senses from the disk drive that a disk is write protected. any write command is ignored. the nwrprt bit also depends upon the state of the force write protect bit in the fdd option register (see the configuration registers section). is vcc 14 ntrk0 this active low schmitt trigger input senses from the disk drive that the head is positioned over the outermost track. is vcc 13 nindex this active low schmitt trigger input senses from the disk drive that the head is positioned over the beginning of a track, as marked by an index hole. is vcc 1 gp40/ drvden0 general purpose i/o drive density select 0 output. indicates the drive and media selected. both functions can be configured as open- drain output. io12 vcc
smsc ds ? LPC47M15X page 13 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 2 gp41/ drvden1 general purpose i/o drive density select 1 output. indicates the drive and media selected. both functions can be configured as open- drain output. io12 vcc 5 serial port 1 interface (8) 84 rxd1 receiver serial data input for port 1. is vcc 85 txd1 transmit serial data output for port 1. o12 vcc 87 nrts1 active low request to send outputs for the serial port. handshake output signal notifies modem that the uart is ready to transmit data. this signal can be programmed by writing to bit 1 of the modem control register (mcr). the hardware reset will reset the nrts signal to inactive mode (high). nrts is forced inactive during loop mode operation. o8 vcc 88 ncts1 active low clear to send inputs for the serial port. handshake signal which notifies the uart that the modem is ready to receive data. the cpu can monitor the status of ncts signal by reading bit 4 of modem status register (msr). a ncts signal state change from low to high after the last msr read will set msr bit 0 to a 1. if bit 3 of the interrupt enable register is set, the interrupt is generated when ncts changes state. the ncts signal has no effect on the transmitter. note: bit 4 of msr is the complement of ncts. i vcc 89 ndtr1 active low data terminal ready outputs for the serial port. handshake output signal notifies modem that the uart is ready to establish data communication link. this signal can be programmed by writing to bit 0 of modem control register (mcr). the hardware reset will reset the ndtr signal to inactive mode (high). ndtr is forced inactive during loop mode operation. o6 vcc 86 ndsr1 active low data set ready input for the serial port. handshake signal which notifies the uart that the modem is ready to establish the communication link. the cpu can monitor the status of ndsr signal by reading bit 5 of modem status register (msr). a ndsr signal state change from low to high after the last msr read will set msr bit 1 to a 1. if bit 3 of interrupt enable register is set, the interrupt is generated when ndsr changes state. note: bit 5 of msr is the complement of ndsr. i vcc
smsc ds ? LPC47M15X page 14 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 91 ndcd1 active low data carrier detect inputs for the serial port. handshake signal which notifies the uart that carrier signal is detected by the modem. the cpu can monitor the status of ndcd signal by reading bit 7 of modem status register (msr). a ndcd signal state change from low to high after the last msr read will set msr bit 3 to a 1. if bit 3 of interrupt enable register is set, the interrupt is generated when ndcd changes state. note: bit 7 of msr is the complement of ndcd. i vcc 90 nri1 active low ring indicator inputs for the serial port. handshake signal which notifies the uart that the telephone ring signal is detected by the modem. the cpu can monitor the status of nri signal by reading bit 6 of modem status register (msr). a nri signal state change from low to high after the last msr read will set msr bit 2 to a 1. if bit 3 of interrupt enable register is set, the interrupt is generated when nri changes state. note: bit 6 of msr is the complement of nri. i vcc 5 infrared interface (2) 61 irrx2/ gp34 infrared receive input /general purpose i/o. gpio can be configured as an open-drain output. is/o8 vcc 62 irtx2/ gp35 infrared transmit output /general purpose i/o. gpio can be configured as an open-drain output. io12 vtr 7, 8, 9 serial port 2 interface (8) 95 gp52/ rxd2 (irrx) general purpose i/o. gpio can be configured as an open-drain output. receive serial data 2 input. see rxd1 pin description above infrared receive input is/o8 vcc 5 96 gp53/ txd2 (irtx) general purpose i/o. gpio can be configured as an open-drain output. transmit serial data 2 output. see txd1 pin description above. infrared transmit output io12 vtr 5, 7, 8 98 gp55/ nrts2 general purpose i/o. gpio can be configured as an open-drain output. request to send 2 output. see nrts1 pin description above. io8 vcc 5 99 gp56/ ncts2 general purpose i/o. gpio can be configured as an open-drain output. clear to send 2 input. see ncts1 pin description above. io8 vcc 5 100 gp57/ ndtr2 general purpose i/o. gpio can be configured as an open-drain output. data terminal ready output. see ndtr1 pin description above. io8 vcc 5
smsc ds ? LPC47M15X page 15 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 97 gp54/ ndsr2 general purpose i/o. gpio can be configured as an open-drain output. data set ready 2 input. see ndsr1 pin description above. io8 vcc 5 94 gp51/ ndcd2 general purpose i/o. gpio can be configured as an open-drain output. data carrier detect 2 input. see ndcd1 pin description above. io8 vcc 5 92 gp50/ nri2 general purpose i/o. gpio can be configured as an open-drain output. ring indicator 2 input. see nri1 pin description above. io8 vcc 5 parallel port interface (17) 66 ninit this output is bit 2 of the printer control register. this is used to initiate the printer when low. refer to pa rallel port description for use of this pin in ecp and epp mode. can be configured as an open-drain output. op14 vcc 67 nslctin this active low output selects the printer. this is the complement of bit 3 of the printer control register. refer to parallel port description for use of this pin in ecp and epp mode. can be configured as an open-drain output. op14 vcc 68 pd0 port data 0 i/o iop14 vcc 69 pd1 port data 1 i/o iop14 vcc 70 pd2 port data 2 i/o iop14 vcc 71 pd3 port data 3 i/o iop14 vcc 72 pd4 port data 4 i/o iop14 vcc 73 pd5 port data 5 i/o iop14 vcc 74 pd6 port data 6 i/o iop14 vcc 75 pd7 port data 7 i/o iop14 vcc 77 slct this high active input from the printer indicates that it has power on. bit 4 of the printer status register reads the slct input. refer to parallel port description for use of this pin in ecp and epp mode. i vcc 78 pe another status input from the printer, a high indicating that the printer is out of paper. bit 5 of the printer status register reads the pe input. refer to parallel port description for use of this pin in ecp and epp mode. i vcc 79 busy this is a status input from the printer, a high indicating that the printer is not ready to receive new data. bit 7 of the printer status register is the complement of the busy input. refer to parallel port description for use of this pin in ecp and epp mode. i vcc 80 nack a low active input from the printer indicating that it has received the data and is ready to accept new data. bit 6 of the printer status register reads the nack input. refer to parallel port description for use of this pin in ecp and epp mode. i vcc
smsc ds ? LPC47M15X page 16 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 81 nerror a low on this input from the printer indicates that there is a error condi tion at the printer. bit 3 of the printer status register reads the nerr input. refer to parallel port description for use of this pin in ecp and epp mode. i vcc 82 nalf this output goes low to cause the printer to automatically feed one line after each line is printed. the nalf output is the complement of bit 1 of the printer control register. refer to parallel port description for use of this pin in ecp and epp mode. can be configured as an open-drain output. op14 vcc 83 nstrobe an active low pulse on this output is used to strobe the printer data into the printer. the nstrobe output is the complement of bit 0 of the printer control register. refer to parallel port description for use of this pin in ecp and epp mode. can be configured as an open-drain output. op14 vcc keyboard/mouse interface (6) 56 kdat keyboard data i/o iod16 vcc 5 57 kclk keyboard clock i/o iod16 vcc 58 mdat mouse data i/o iod16 vcc 5 59 mclk mouse clock i/o iod16 vcc 63 gp36/ nkbdrst general purpose i/o. gpio can be configured as an open-drain output. keyboard reset open-drain output io8 vcc 10 64 gp37/ a20m general purpose i/o. gpio can be configured as an open-drain output. gate a20 open-drain output io8 vcc 10 game port (8) 32 gp10/ j1b1 general purpose i/o. gpio can be configured as an open-drain output. joystick 1 button 1 input is/o8 vcc 5 33 gp11/ j1b2 general purpose i/o. gpio can be configured as an open-drain output joystick 1 button 2 input is/o8 vcc 5 34 gp12/ j2b1 general purpose i/o. gpio can be configured as an open-drain output joystick 2 button 1 input is/o8 vcc 5 35 gp13 j2b2 general purpose i/o. gpio can be configured as an open-drain output joystick 2 button 2 input is/o8 vcc 5 36 gp14/ j1x general purpose i/o. gpio can be configured as an open-drain output joystick 1 x-axis i/o io12 vcc 5 37 gp15/ j1y general purpose i/o. gpio can be configured as an open-drain output joystick 1 y-axis i/o io12 vcc 5 38 gp16/ j2x general purpose i/o. gpio can be configured as an open-drain output joystick 2 x-axis i/o io12 vcc 5
smsc ds ? LPC47M15X page 17 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes 39 gp17/ j2y general purpose i/o. gpio can be configured as an open-drain output joystick 2 y-axis i/o io12 vcc 5 general purpose i/o (11) 17 gp42/ nio_pme general purpose i/o. power management event output. this active low power management event signal allows the LPC47M15X to request wakeup. both functions can be configured as open- drain outputs. io12 vtr 9 28 gp43/ ddrc general purpose i/o. gpio can be configured as an open-drain output. device disable reg. control input io8 vcc 5 41 gp20/ p17 general purpose i/o 8042 p17 i/o both functions can be configured as open- drain output io8 vcc 5 42 gp21/ p16/ nds1 general purpose i/o 8042 p16 i/o drive select 1 output all three functions can be configured as open-drain output. io12 vcc 5 43 gp22/ p12/ nmtr1 general purpose i/o 8042 p12 i/o motor on 1 output all three functions can be configured as open-drain output. io12 vcc 5 45 gp24 (sysopt) general purpose i/o. gpio can be configured as an open-drain output. system option. at the trailing edge of hardware reset or vcc por this pin is latched to determine the configuration base address: 0 = index base i/o address 02e hex; 1 = index base i/o address 04e hex. io8 vcc 5, 11 46 gp25/ midi_in general purpose i/o. gpio can be configured as an open-drain output. mpu-401 midi input io8 vcc 5 47 gp26/ midi_out general purpose i/o. gpio can be configured as an open-drain output. mpu-401 midi output io12 vcc 5 48 gp60/ led1 general purpose i/o. gpio can be configured as an open-drain output. led 1 output io12 vtr 5, 12 49 gp61 led2 general purpose i/o. gpio can be configured as an open-drain output. led 2 output io12 vtr 5, 12 50 gp27/ nio_smi general purpose i/o active low system management interrupt output. both functions can be configured as open- drain outputs. io12 vcc 5
smsc ds ? LPC47M15X page 18 rev. 08/02/2001 qfp pin# name description buffer name pwr well notes hardware monitoring block (28) 102, 111, 121, 122 hvcc +3.3v vcc pin dedicated to the hardware monitoring block. can be powered by +3.3v standby power if monitoring in low power states is required. 1 101, 112, 125, 126, 127, 128 hvss analog ground. internally connected to all of the hardware monitoring block circuitry. 1 103 sda system management bus bi-directional data. open drain output. i m od3 hvcc 104 sclk system management bus clock. i m hvcc 105 a0/ nreset/ ntherm/ xnor_out the lowest order programmable bit of the smbus address input. minimum 20msec low reset output pulse interrupt output for temperature and voltage interrupts. xnor-chain test mode output the nreset and ntherm are open-drain outputs i m o3 hvcc 106 vid0 voltage id 0 input i m hvcc 107 vid1 voltage id 1 input i m hvcc 108 vid2 voltage id 2 input i m hvcc 109 vid3 voltage id 3 input i m hvcc 110 12v_in/ vid4 defaults to analog input for +12v. optionally, can be configured to read the vid4 digital input, a voltage supply readout from the processor. this value is read in the vid4 register. i ang /i m hvcc 115 +5v_in analog input for +5v i ang 116 +3.3v_in analog input for +3.3v i ang 117 +2.5v_in analog input for +2.5v i ang 118 vccp_in analog input for +vccp (processor voltage: 0 to 3.0v). i ang 119 +1.8v_in analog input for +1.8v i ang 120 +1.5v_in analog input for +1.5v i ang 113 d0-/ xnor_in this is the negative analog input (current sink) from the remote thermal diode. this serves as the negative input into the a/d. digital input. if held high at power-up, initiates xnor chain test mode. i ang /i m hvcc 114 d0+ this is the positive input (current source) from the remote thermal diode. this serves as the positive input into the a/d. i ang hvcc 123 d1+ see d0+ description. i ang hvcc 124 d1- see d0- negative analog input description. i ang hvcc note: the ?n? as the first letter of a signal name or the ?# ? as the suffix of a signal name indicates an ?active low? signal. note 1: vcc and vss pins are for super i/o blocks. hvcc and hvss are dedicated for t he hardware monitoring block. note 2: vtr can be connected to vcc if no wakeup functionality is required. note 3: if the 32khz input clock is not used the clki32 pin must be grounded. there is a bit in the configuration register at 0xf0 in logical device a that indicates whether or not the 32khz clock is connected. this bit
smsc ds ? LPC47M15X page 19 rev. 08/02/2001 determines the clock source for the fan tachometer, led a nd ?wake on specific key? logic. set this bit to ?1? if the clock is not connected. note 4: the nlpcpd pin may be tied high. the lpc interf ace will function properly if the npci_reset signal follows the protocol defined for the nlreset signal in the ?low pin count interface specification?. note 5: these pins are inputs to vcc and vtr powered logic. note 6: the fan control pins (fan1 and fan2) come up as outputs and low following a vcc por and hard reset. note 7: the irtx pins (irtx2/gp35 and gp53/txd2(irtx)) are driven low when the part is powered by vtr (vcc=0v with vtr=3.3v). these pins will remain lo w following a power-up (vcc por) until serial port 2 is enabled by setting the activate bit, at which time the pin will reflect the state of the transmit output of the serial port 2 block. note 8: the vcc power-up default for this pin is logic ?0? if the irtx function is programmed on the gpio. note 9: these pins are inputs to vcc powered logic. note 10: external pullups must be placed on the nkbdrst and a 20m pins. these pins are gpios that are inputs after an initial power-up (vtr por). if the nkbdrst and a20m functions are to be used, the system must ensure that these pins are high. see section ?pins that require external pullup resistor?. note 11: the gp24 /sysopt pin requires an external pulldown resistor to put the base io address for configuration at 0x02e. an external pullup resistor is required to move the base io address for configuration to 0x04e. note 12: the led pins are powered by vtr so that the leds can be controlled when the part is under vtr power. 3.1 buffer name descriptions note: the buffer type values ar e specified at vcc=3.3v i input ttl compatible - super i/o block. i m input - hardware monitoring block. i ang analog input, hardware monitoring block. is input with schmitt trigger. i m od3 input/output (open drain), 3ma sink. i m o3 input/output, 3ma sink, 3ma source. o6 output, 6ma sink, 3ma source. o8 output, 8ma sink, 4ma source. od8 open drain output, 8ma sink. io8 input/output, 8ma sink, 4ma source. is/o8 input with schmitt trigger/output, 8ma sink, 4ma source. o12 output, 12ma sink, 6ma source. od12 open drain output, 12ma sink. io12 input/output, 12ma sink, 6ma source. od14 open drain output, 14ma sink. op14 output, 14ma sink, 14ma source. iop14 input/output, 14ma sink, 14ma source. backdriv e protected. iod16 input/output (open drain), 16ma sink. pci_io input/output. these pins must meet the pc i 3.3v ac and dc char acteristics. (note 1) pci_o output. these pins must meet the pc i 3.3v ac and dc characteristics. (note 1) pci_i input. these pins must meet the pci 3.3v ac and dc characteristics. (note 1) pci_iclk clock input. these pins must meet the pci 3.3v ac and dc characteristics and timing. (note 2) note 1: see the ?pci local bus specificat ion,? revision 2.1, section 4.2.2. note 2: see the ?pci local bus specification, ? revision 2.1, section 4.2.2 and 4.2.3.
smsc ds ? LPC47M15X page 20 rev. 08/02/2001 3.2 pins that require external pullup resistors 3.2.1 super i/o pins the following pins require external pullup resistors: kdat kclk mdat mclk gp36/kbdrst if kbdrst function is used gp37/a20m if a20m function is used gp20/p17 if p17 function is used as an open drain output gp21/p16/nds1 if p16 or nds1 func tion is used as open drain output gp22/p12/nmtr1 if p12 or nmtr1 func tion is used as open drain output gp27/nio_smi if nio_smi function is used gp42/nio_pme if nio_pme function is used ser_irq gp40/drvden0 if drvden0 functi on is used as an open drain. gp41/drvden1 if drvden1 functi on is used as an open drain. nmtr0 if used as an open drain output nds0 if used as an open drain output ndir if used as an open drain output nstep if used as an open drain output nwdata if used as an open drain output nwgate if used as an open drain output nhdsel if used as an open drain output nindex ntrk0 nwrtprt nrdata ndskchg gpios 3.2.2 hardware monitoring block pins the following pins require external pullup resistors to 3.3v only: sclk sda a0/nreset/ntherm/xnor_out if the nreset or ntherm function is used (unless external circuitry is provided). this limits the smbus address to 0101101. see section 6.18.2 smbus interface on page 129. vid0-vid3 12v_in/vid4 if vid4 function is used.
smsc ds ? LPC47M15X page 21 rev. 08/02/2001 4. block diagram fan2* j1x, j1y* irtx2* irrx2* LPC47M15X (128 qfp) digital data separator with write precom- pensation smc proprietary 82077 compatible vertical floppydisk controller core wdata wclock rclock rdata game port fan control 2nd infrared port multi-mode parallel port with chiprotect tm / fdc mux (see lpc47b27x) pd[7,0] busy, slct, pe, error, ack strobe, init, slctin, alf fan_tach2* fan_tach1* fan1* j2b1, j2b2* j1b1, j1b2* j2x, j2y* leds led2* led1* internal bus (data, address, and control lines) high-speed 16550a uart port 1 txd1, rxd1 dsr1, dtr1 dcd1, ri1 cts1, rts1 mpu-401 serial port midi_out* midi_in* keyboard/mouse 8042 controller kclk, mclk kdata, mdata gatea20* kreset* p12*, p16*, p17* high-speed 16550a uart port 2 txd2 (irtx)*, rxd2 (irrx)* dsr2*, dtr2* dcd2*, ri2* cts2*, rts2 * power mgmt nio_pme* nio_smi* general purpose i/o gp1[0:7]* gp2[0:2,4:7]* gp3[0:7]*, gp4[0:3]* gp5[0:7]*, gp6[0:1]* rdata, wdata dir, step, dskchg, ds0, ds1* mtr0, mtr1*,trk0, index, wrtprt drvden0*, drvden1* wgate, hdsel note 1: this diagram does not show power and ground connections. note 2: functions with "*" are located on multifunctional pins. this diagram is designed to show the various functions available on the chip (not pin layout). hardware monitoring smbus clock gen clk32 clocki lad[3:0] nlframe nldrq npci_reset nlpcpd ser_irq pci_clk lpc bus interface serial irq a0/nreset/ntherm/ xnor_out vccp_in +3.3v_in +2.5v_in sda sclk vid0 vid1 vid2 vid3 12v_in/vid4 +5v_in hvss hvcc +1.8v_in +1.5v_in d1+ d1- d0+ d0- figure 1 ? LPC47M15X block diagram
smsc ds ? LPC47M15X page 22 rev. 08/02/2001 5. power functionality the LPC47M15X has four power planes: vcc, hvcc, vref, and vtr. 5.1 vcc/hvcc power the LPC47M15X is a 3.3 volt part. the vcc/hvcc supply is 3.3 volts (nominal). vcc is supply for super i/o block, and hvcc is supply for the hardware monitoring blo ck. see the ?operational description? section and the ?maximum current values? subsection. 5.1.1 3 volt operation / 5 volt tolerance the LPC47M15X is a 3.3 volt part. it is intended solely for 3.3v applications. non-lpc bus pins are 5v tolerant; that is, the operating input voltage is 5.5v max, and the i/o buffer output pads are bac kdrive protected (they do not impose a load on any external vcc/hvcc powered circ uitry). the 5v tolerant pins are applicable to the super i/o block only. the lpc interface pins are 3.3 v only. these signals meet pci dc specifications for 3.3v signaling. these pins are: ? lad[3:0] ? nlframe ? nldrq ? nlpcpd the input voltage for all other pins is 5.5v max. these pins include all non-lpc bus pins and the following pins in the super i/o block: ? npci_reset ? pci_clk ? ser_irq ? nio_pme the hardware monitoring block digital pins are 3.3v only. 5.2 vref pin the LPC47M15X has a reference voltage pin input on pin 44 of the part. this reference voltage can be connected to either a 5v supply or a 3.3v supply. it is used for the game port. see the ?game port logic? section. 5.3 vtr support the LPC47M15X requires a trickle supply (v tr ) to provide sleep current for the programmable wake-up events in the pme interface when v cc is removed. the vtr supply is 3.3 volts (nominal). see the operational description section. the maximum vtr current that is required depends on the functions that are used in the part. see trickle power functionality subsection and maximum current valu es subsection. if the LPC47M15X is not intended to provide wake-up capabilities on standby current, v tr can be connected to v cc . v tr powers the ir interface, the pme configuration registers, and the pme interface. the v tr pin generates a v tr power-on-reset signal to initialize these components. note: if v tr is to be used for programmable wake-up events when v cc is removed, v tr must be at its full minimum potential at least 10 us before v cc begins a power-on cycle. when v tr and v cc are fully powered, the potential difference between the two supplies must not exceed 500mv. 5.3.1 trickle power functionality when the LPC47M15X is running under vtr only (vcc removed), pme wakeup events are active and (if enabled) able to assert the nio_pme pin active low. the following lists the wakeup events: ? uart 1 ring indicator ? uart 2 ring indicator ? keyboard data ? mouse data ? ?wake on specific key? logic ? fan tachometers (note) ? gpios for wakeup. see below. note: the fan tachometers can generate a pme when vcc= 0. clear the enable bits for the fan tachometers before removing fan power.
smsc ds ? LPC47M15X page 23 rev. 08/02/2001 the following requirements apply to all i/o pins that are specified to be 5 volt tolerant: i/o buffers that are wake-up event co mpatible are powered by vcc. unde r vtr power (vcc=0), these pins may only be configured as inputs. these pins have input buffe rs into the wakeup logic that are powered by vtr. i/o buffers that may be configured as either push-pull or op en drain under vtr power (vcc=0), are powered by vtr. this means, at a minimum, they will source their specified current from vtr even when vcc is present. the gpios that are used for pme wakeup as input ar e gp10-gp17, gp20-gp22, gp 24-gp27, gp30-gp33, gp41, gp43, gp50-gp57, gp60, gp61. these gpios function as follows (with the exception of gp53, gp60 and gp61 - see below): buffers are powered by vcc, but in the absence of vcc they are backdrive protected (they do not impose a load on any external vtr powered circuitry). they are wake up compatible as inputs under vtr power. these pins have input buffers into the wakeup logic that are powered by vtr. all gpios listed above are for pme wakeup as a gpio (or alternate function). note that gp32 and gp33 cannot be used for wakeup under vtr power (vcc=0) since these are t he fan control pins which come up as outputs and low following a vcc por and hard reset. gp53 cannot be used for wakeup under vtr power since this is the irtx pin which comes up as output and low following a vtr por, a vcc por and hard reset. gp43 reverts to the basic gpio function when vcc is removed from the part, but its programmed input/output, invert/non-invert and output buffer type is retained. the other gpios function as follows: gp34, gp36, gp37 and gp40: buffers are powered by vcc. in the absence of vcc they are backdrive protected. these pins do not have input buffers into the wakeup logic that are powered by vtr, and are not used for wakeup. gp35, gp42, gp53, gp60 and gp61: buffers powered by vtr. gp35 and gp53 have irtx as the alternate function and their output buffers are powered by vtr so that the pins are always forced low when not used. gp35 and gp53 cannot be used for wakeup. gp42 is the nio_pme pin which is active under vtr. gp60 and gp61 have led as the alternate function and the logic is able to control the pin under vtr. the irtx pins (irtx2/gp35 and gp53/txd2(irtx)) are power ed by vtr so that they are driven low when vcc = 0v with vtr = 3.3v. these pins will remain low following a vcc por until serial port 2 is enabled by setting the activate bit, at which time the pin will reflect the stat e of the transmit output of t he serial port 2 block. the following list summarizes the blocks, re gisters and pins that are powered by vtr: ? pme interface block ? pme runtime register block (includes all pme, sm i, gpio, fan and other miscellaneous registers) ? ?wake on specific key? logic ? led control logic ? fan tachometers ? pins for pme wakeup: - gp42/nio_pme (output, buffer powered by vtr) - nri1 (input) - gp50/nri2 (input) - kdat (input) - mdat (input) - gpios (gp10-gp17, gp20-gp22, gp24-gp27, gp30-gp33, gp41, gp43, gp50-gp57, gp60, gp61) ? all input-only except gp53, gp60, gp61. see below. ? other pins - irtx2/gp35 (output, buffer powered by vtr) - gp53/txd2(irtx) (output, buffer powered by vtr) - gp60/led1 (output, buffer powered by vtr) - gp61/led2 (output, buffer powered by vtr)
smsc ds ? LPC47M15X page 24 rev. 08/02/2001 5.4 32.768 khz trickle clock input the LPC47M15X utilizes a 32.768 khz trickle input to supply a clock signal for the fan tachometer logic, led blink and wake on specific key function. indication of 32khz clock there is a bit to indicate whether or not the 32khz clock in put is connected to the LPC47M15X. this bit is located at bit 0 of the clocki32 register at 0xf0 in logical device a. this register is powered by vtr and reset on a vtr por. bit[0] (clk32_prsn) is defined as follows: 0=32khz clock is connected to the clki32 pin (default) 1=32khz clock is not connected to the clki32 pin (pin is grounded). bit 0 controls the source of the 32khz (nominal) clock for the fan tachometer logic, t he led blink logic and the ?wake on specific key? logic. when the external 32khz clock is connected, that will be the source for the fan tachometer, led and ?wake on specific key? logic. when the external 32khz clock is not connected, an internal 32khz clock source will be derived from the 14mhz clock for the f an tachometer, led and ?wake on specific key? logic. the following functions will not work under vtr power (vcc removed) if the external 32khz clock is not connected. these functions will work under vcc power even if the external 32 khz clock is not connected. ? fan tachometer ? wake on specific key ? led blink 5.5 internal pwrgood an internal pwrgood logical control is include d to minimize the effects of pin-st ate uncertainty in the host interface as v cc cycles on and off. when the internal pwrgood signal is ?1? (active), v cc > 2.3v (nominal), and the LPC47M15X host interface is active. when the internal pwrgood signal is ?0? (inactive), v cc <= 2.3v (nominal), and the LPC47M15X host interface is inactive; that is, lpc bus reads and writes will not be decoded. the LPC47M15X device pins nio_pme, clocki32, kdat, md at, nri1, nri2, rxd2 and mo st gpios (as input) are part of the pme interface and remain active when the internal pwr good signal has gone i nactive, provided v tr is powered. the irtx2/gp35, gp53/txd2 (irtx), gp60/led1 and gp61/led2 pins also remain active when the internal pwrgood signal has gone inactive, provided v tr is powered. see trickle power functionality section. the internal pwrgood signal is also used to disable the ir half duplex timeout. 5.6 maximum current values see the ?operational description? sect ion for the maximum current values. 5.6.1 super i/o functions the maximum vtr current, i tr , is given with all outputs open (not load ed), and all inputs transitioning from/to 0v to/from 3.3v. the total maximum current for the part is the unloaded value plus the maximum current sourced by the pin that is driven by vtr. t he pins that are powered by vtr are as follows: gp42/nio_pme, irtx2/gp35, gp53/txd2(irtx), gp60/led1, gp61/led2, and clki32. t hese pins, if configured as push-pull outputs, will source a minimum of 6ma at 2.4v when driving. the maximum vcc current, i cc , is given with all outputs open (not loaded) and all inputs transitioning from/to 0v to/from 3.3v.
smsc ds ? LPC47M15X page 25 rev. 08/02/2001 5.6.2 hardware monitoring block functions the maximum supply current for the hardware monitoring block, powered by hvcc, is shown in the ?hardware monitoring block specifications? section of the ?operation de scription? section. 5.7 power management events (pme/sci) the LPC47M15X offers support for power management events (pmes), also referred to as system control interrupt (sci) events. the terms pme and sci are used synonymously th roughout this document to refer to the indication of an event to the chipset via the assertion of the nio_pme output signal on pin 17. see the ?pme support? section.
smsc ds ? LPC47M15X page 26 rev. 08/02/2001 6. functional description the following sections describe the func tional blocks located in the LPC47M15X (see figure 1). a ll the functional blocks are dedicated to the super i/o portion of the chip, ex cept for the hardware monitoring block. the hardware monitoring block is maintained separately from the super i/o components and is defined in section 6.18 ? hardware monitoring interface. it is powered by hvcc and all its registers are accessed through an internal address register located in the hardware monitoring block (see section 9 ? registers for hardware monitoring block on page 182). the various super i/o components are descr ibed in the following se ctions and their regist ers are implemented as typical plug-and-play components (see section 8 ? configuration on page 164). it should be noted that there are two main interfaces used to access the components of this chip. the lpc interface is used to access the super i/o register s and the smbus is used to access the hardware monitoring registers. 6.1 super i/o registers the address map, shown below in table 1 shows the addre sses of the different blocks of the super i/o immediately after power up. the base addresses of the fdc, serial and parallel ports, pme register block, game port and configuration register block can be mov ed via the configuration registers. some addresses are used to access more than one register. 6.2 host processor interface (lpc) the host processor communicates with the LPC47M15X through a series of read/write register s via the lpc interface. the port addresses for these r egisters are shown in table 1. register access is accomplished through i/o cycles or dma transfers. all registers are 8 bits wide. table 1 ? super i/o block addresses address block name logical device notes base+(0-5) and +(7) floppy disk 0 base+(0-7) serial port com 1 4 base1+(0-7) base2+(0-7) serial port com 2 5 base+(0-3) base+(0-7) base+(0-3), +(400-402) base+(0-7), +(400-402) parallel port spp epp ecp ecp+epp+spp 3 60, 64 kybd 7 base + 0 game port 9 base + (0-5f) runtime registers a note 1 base + (0-1) mpu-401 b base + (0-1) configuration note: refer to the configuration register descriptions for setting the base address. note 1: logical device a is refered to as the runtim e register block or pme block and may be used interchangeably throughout this document.
smsc ds ? LPC47M15X page 27 rev. 08/02/2001 6.3 lpc interface the following sub-sections specify th e implementation of the lpc bus. 6.3.1 lpc interface signal definition the signals required for the lpc bus interface are descri bed in the table below. lpc bus signals use pci 33mhz electrical signal characteristics. signal name type description lad[3:0] i/o lpc address/data bus. mult iplexed command, address and data bus. nlframe input frame signal. indicates start of new cycle and termination of broken cycle npci_reset input pci reset. used as lpc interface reset. nldrq output encoded dma/bus master request for the lpc interface. nio_pme od power mgt event signal. allows the LPC47M15X to request wakeup. nlpcpd input powerdown signal. indicates that the lpc4 7m15x should prepare for power to be shut on the lpc interface. ser_irq i/o serial irq. pci_clk input pci clock. note: the nclkrun signal is not implemented in this part. 6.3.2 lpc cycles the following cycle types are supported by the lpc protocol. cycle type transfer size i/o write 1 byte i/o read 1 byte dma write 1 byte dma read 1 byte LPC47M15X ignores cycles that it does not support. 6.3.3 field definitions the data transfers are based on specific fields that are us ed in various combinations, depending on the cycle type. these fields are driven onto the lad[3: 0] signal lines to communicate address, control and data information over the lpc bus between the host and the LPC47M15X. see the low pin count (lpc) interface specification revision 1.0 from intel, section 4.2 for definition of these fields. 6.3.4 nlframe usage nlframe is used by the host to indicate the start of cycles and the termination of cycles due to an abort or time-out condition. this signal is to be used by the LPC47M15X to know when to monitor the bus for a cycle. this signal is used as a general notificatio n that the lad[3:0] lines contain information relative to the start or stop of a cycle, and that the LPC47M15X monito rs the bus to determine whether the cycle is intended for it. the use of nlframe allows the LPC47M15X to enter a lower power st ate internally. there is no need for the LPC47M15X to monitor the bus when it is inactive, so it can decouple its st ate machines from the bus, and internally gate its clocks. when the LPC47M15X samples nlframe active, it immediatel y stops driving the lad[3:0] signal lines on the next clock and monitor the bus for new cycle information. the nlframe signal functions as described in the low pin count (lpc) interface specification, revision 1.0. 6.3.5 i/o read and write cycles the LPC47M15X is the target for i/o cycles . i/o cycles are initiated by the host for register or fifo accesses, and will generally have minimal sync times. the minimum number of wait-states between bytes is 1. epp cycles will depend on the speed of the external device, and may have much longer sync times. data transfers are assumed to be exactly 1-byte. if the cp u requested a 16 or 32-bit transfer, the host will break it up into 8-bit transfers.
smsc ds ? LPC47M15X page 28 rev. 08/02/2001 see the ?low pin count (lpc) interface sp ecification? reference, se ction 5.2, for the sequenc e of cycles for the i/o read and write cycles. 6.3.6 dma read and write cycles dma read cycles involve the transfer of data from the host (main memory) to the LPC47M15X. dma write cycles involve the transfer of data fr om the LPC47M15X to the host (main memory). data will be coming from or going to a fifo and will have minimal sync times. data trans fers to/from the LPC47M15X are 1, 2 or 4 bytes. see the ?low pin count (lpc) interface specification? reference, section 6. 4, for the field definitions and the sequence of the dma read and write cycles. 6.3.7 dma protocol dma on the lpc bus is handled through the use of the nldrq lines from the LPC47M15X and special encodings on lad[3:0] from the host. the dma mechanism for the lpc bus is described in the ?low pin count (lpc) interface s pecification,? revision 1.0. 6.3.8 power management clockrun protocol the nclkrun pin is not implemented in the LPC47M15X. see the ?low pin count (lpc) interface sp ecification? revision 1.0, section 8.1. lpcpd protocol see the ?low pin count (lpc) interface sp ecification? revision 1.0, section 8.2. 6.3.9 sync protocol see the ?low pin count (lpc) interface specification? revision 1.0, section 4.2.1.8 for a table of valid sync values. typical usage the sync pattern is used to add wait states. for read cy cles, the LPC47M15X immediately drives the sync pattern upon recognizing the cycle. the host immediately drives the sync pattern for write cycles. if the LPC47M15X needs to assert wait states, it does so by driv ing 0101 or 0110 on lad[3:0] unt il it is ready, at which poi nt it will drive 0000 or 1001. the LPC47M15X will choose to assert 0101 or 0110, but not switch between the two patterns. the data (or wait state sync) will immediately follow the 0000 or 1001 value. the sync value of 0101 is intended to be used for normal wait states, wh erein the cycle will complete within a few clocks. the LPC47M15X uses a sync of 0101 for all wait states in a dma transfer. the sync value of 0110 is intended to be used where the number of wait states is large. this is provided for epp cycles, where the number of wait stat es could be quite large (>1 microsecon d). however, the LPC47M15X uses a sync of 0110 for all wait states in an i/o transfer. the sync value is driven within 3 clocks. sync timeout the sync value is driven within 3 clocks. if the host obs erves 3 consecutive clocks without a valid sync pattern, it will abort the cycle. the LPC47M15X does not assume any particular timeout. when the host is driving sync, it may have to insert a very large number of wait states, depending on pci latencies and retries.
smsc ds ? LPC47M15X page 29 rev. 08/02/2001 sync patterns and maximum number of syncs if the sync pattern is 0101, then the host assume s that the maximum number of syncs is 8. if the sync pattern is 0110, then no maximum number of syncs is assumed. the LPC47M15X has protection mechanisms to complete the cycle. this is used for epp data transfers and should utilize the same timeout protection that is in epp. sync error indication the LPC47M15X reports errors vi a the lad[3:0] = 1010 sync encoding. if the host was reading data from the lpc4 7m15x, data will still be transferred in th e next two nibbles. this data may be invalid, but it will be transferred by the LPC47M15X. if the host was writ ing data to the LPC47M15X, the data had already been transferred. in the case of multiple byte cycles, such as memory and dma cycles, an error sync terminates the cycle. therefore, if the host is transferring 4 bytes from a device, if the device returns the error sync in the first byte, the other three bytes will not be transferred. i/o and dma start fields i/o and dma cycles use a start field of 0000. reset policy the following rules gove rn the reset policy: when npci_reset goes inactive (high), the clock is assumed to have been running for 100usec prior to the removal of the reset signal, so that ev erything is stable. this is the same reset active time after clock is stable that is used for the pci bus. when npci_reset goes active (low): the host drives the nlframe signal high, tristates t he lad[3:0] signals, and ignores the nldrq signal. the LPC47M15X must ignore nlframe, tris tate the lad[3:0] pins and drive the nldrq signal inactive (high). 6.3.10 lpc transfers wait state requirements i/o transfers the LPC47M15X inserts three wait stat es for an i/o read and two wait states for an i/o write cycle. a sync of 0110 is used for all i/o transfers. the exception to this is for transfers where iochrdy would normally be deasserted in an isa transfer (i.e., epp or ircc transfers) in which case the sync pattern of 0110 is used and a large number of syncs may be inserted (up to 330 which corresponds to a timeout of 10us). dma transfers the LPC47M15X inserts three wait states for a dma read an d four wait states for a dma write cycle. a sync of 0101 is used for all dma transfers. see the example timing for the lpc cycl es in the ?timing diagrams? section. 6.4 floppy disk controller the floppy disk controller (fdc) provid es the interface between a host microprocessor and the floppy disk drives. the fdc integrates the functions of the formatter/contro ller, digital data separator, write precompensation and data rate selection logic for an ibm xt/at compatible f dc. the true cmos 765b core guarantees 100% ibm pc xt/at compatibility in addition to providing data overflow and underflow protection. LPC47M15X supports two floppy drive directly (see ?direct support for two floppy drives? subsection). the fdc is compatible to the 82077aa using smsc?s proprietary floppy disk controller core. 6.4.1 fdc internal registers the floppy disk controller contains eight internal regi sters which facilitate the interfacing between the host microprocessor and the disk drive. table 2 shows the addresse s required to access these registers. registers other
smsc ds ? LPC47M15X page 30 rev. 08/02/2001 than the ones shown are not supp orted. the rest of the description assu mes that the primary addresses have been selected. table 2 ? status, data and control registers (shown with base addresses of 3f0 and 370) primary address secondary address r/w register 3f0 3f1 3f2 3f3 3f4 3f4 3f5 3f6 3f7 3f7 370 371 372 373 374 374 375 376 377 377 r r r/w r/w r w r/w r w status register a (sra) status register b (srb) digital output register (dor) tape drive register (tdr) main status register (msr) data rate select register (dsr) data (fifo) reserved digital input register (dir) configuration control register (ccr) status register a (sra) address 3f0 read only this register is read-only and monitors the state of the inte rnal interrupt signal and several disk interface pins in ps/2 and model 30 modes. the sra can be accessed at any ti me when in ps/2 mode. in the pc/at mode the data bus pins d0 ? d7 are held in a high im pedance state for a read of address 3f0. ps/2 mode 7 6 5 4 3 2 1 0 int pending ndrv2 step ntrk0 hdsel nindx nwp dir reset cond. 0 1 0 n/a 0 n/a n/a 0 bit 0 direction active high status indicating the direction of head move ment. a logic ?1? indicates inward direction; a logic ?0? indicates outward direction. bit 1 nwrite protect active low status of the write protect disk interface inpu t. a logic ?0? indicates that the disk is write protected. bit 2 nindex active low status of the index disk interface input. bit 3 head select active high status of the hdsel disk interface input. a logic ?1? selects side 1 and a logic ?0? selects side 0. bit 4 ntrack 0 active low status of the trk0 disk interface input. bit 5 step active high status of the step output disk interface output pin. bit 6 ndrv2 this function is not supported. this bit is always read as ?1?. bit 7 interrupt pending active high bit indicating the state of the floppy disk interrupt output.
smsc ds ? LPC47M15X page 31 rev. 08/02/2001 ps/2 model 30 mode bit 0 direction active low status indicating the direction of head movement. a logic ?0? indicates inward direction; a logic ?1? indicates outward direction. bit 1 write protect active high status of the write protect disk interface inpu t. a logic ?1? indicates that the disk is write protected. bit 2 index active high status of t he index disk interface input. bit 3 head select active low status of the hdsel disk interface input. a logic ?0? selects side 1 and a logic ?1? selects side 0. bit 4 track 0 active high status of the trk0 disk interface input. bit 5 step active high status of the latched step disk interface output pin. this bit is latched with the step output going active, and is cleared with a read from the dir register, or with a hardware or software reset. bit 6 dma request active high status of the dma request pending. bit 7 interrupt pending active high bit indicating the state of the floppy disk interrupt. status register b (srb) address 3f1 read only this register is read-only and monitors the state of several disk interface pins in ps/2 and model 30 modes. the srb can be accessed at any time when in ps/2 mode. in the pc/at mode the data bus pins d0 ? d7 are held in a high impedance state for a read of address 3f1. ps/2 mode 7 6 5 4 3 2 1 0 1 1 drive sel0 wdata toggle rdata toggle wgate mot en1 mot en0 reset cond. 1 1 0 0 0 0 0 0 bit 0 motor enable 0 active high status of the mtr0 disk interface output pin. this bit is low after a hardware reset and unaffected by a software reset. 7 6 5 4 3 2 1 0 int pending drq step f/f trk0 nhdsel indx wp ndir reset cond. 0 0 0 n/a 1 n/a n/a 1
smsc ds ? LPC47M15X page 32 rev. 08/02/2001 bit 1 motor enable 1 active high status of the mtr1 disk interface output pin. this bit is low after a hardware reset and unaffected by a software reset. bit 2 write gate active high status of t he wgate disk interface output. bit 3 read data toggle every inactive edge of the rdata input causes this bit to change state. bit 4 write data toggle every inactive edge of the wdata input causes this bit to change state. bit 5 drive select 0 reflects the status of the drive select 0 bit of the dor (address 3f2 bit 0). this bit is cleared after a hardware reset and it is unaffected by a software reset. bit 6 reserved always read as a logic ?1?. bit 7 reserved always read as a logic ?1?. ps/2 model 30 mode bit 0 ndrive select 2 the ds2 disk interface is not supported. bit 1 ndrive select 3 the ds3 disk interface is not supported. bit 2 write gate active high status of the latched wgat e output signal. this bit is latched by the active going edge of wgate and is cleared by the read of the dir register. bit 3 read data active high status of the latched rdata output signal. this bit is latched by the inactive going edge of rdata and is cleared by the read of the dir register. bit 4 write data active high status of the latched wdata output signal. th is bit is latched by the inactive going edge of wdata and is cleared by the read of the dir register . this bit is not gated with wgate. bit 5 ndrive select 0 active low status of the ds0 disk interface output. bit 6 ndrive select 1 active low status of the ds1 disk interface output. 7 6 5 4 3 2 1 0 ndrv2 nds1 nds0 wdata f/f rdata f/f wgate f/f nds3 nds2 reset cond. n/a 1 1 0 0 0 1 1
smsc ds ? LPC47M15X page 33 rev. 08/02/2001 bit 7 ndrv2 active low status of the drv2 disk interface inpu t. note: this function is not supported. digital output register (dor) address 3f2 read/write the dor controls the drive select and motor enables of the disk interface outputs. it also contains the enable for the dma logic and a software reset bit. the contents of the dor are unaffected by a software reset. the dor can be written to at any time. 7 6 5 4 3 2 1 0 mot en3 mot en2 mot en1 mot en0 dmaen nreset drive sel1 drive sel0 reset cond. 0 0 0 0 0 0 0 0 bit 0 and 1 drive select these two bits are binary encoded for the drive selects, t hereby allowing only one drive to be selected at one time. bit 2 nreset a logic ?0? written to this bit resets the floppy disk controller . this reset will remain active until a logic ?1? is written to this bit. this software reset does not affect the dsr and ccr registers, no r does it affect the other bits of the dor register. the minimum reset duration required is 100ns, t herefore toggling this bit by consecutive writes to this register is a valid method of issuing a software reset. bit 3 dmaen pc/at and model 30 mode: writing this bit to logic ?1? will enable the dma and interrupt functions. this bit being a logic ?0? will disable the dma and interrupt functions. this bit is a logic ?0? after a reset and in these modes. ps/2 mode: in this mode the dma and interrupt functions are always enabled. during a reset, this bit will be cleared to a logic ?0?. bit 4 motor enable 0 this bit controls the mtr0 disk interface output. a logi c ?1? in this bit will cause the output pin to go active. bit 5 motor enable 1 this bit controls the mtr1 disk interface output. a logi c ?1? in this bit will cause the output pin to go active. drive dor value 0 1ch 1 2dh table 3 ? internal 2 drive decode ? normal digital output register drive select outputs (active low) motor on outputs (active low) bit 5 bit 4 bit1 bit 0 nds1 nds0 nmtr1 nmtr0 x 1 0 0 1 0 nbit 5 nbit 4 1 x 0 1 0 1 nbit 5 nbit 4 0 0 x x 1 1 nbit 5 nbit 4
smsc ds ? LPC47M15X page 34 rev. 08/02/2001 table 4 ? internal 2 drive decode ? drives 0 and 1 swapped digital output register drive select outputs (active low) motor on outputs (active low) bit 5 bit 4 bit1 bit 0 nds1 nds0 nmtr1 nmtr0 x 1 0 0 0 1 nbit 4 nbit 5 1 x 0 1 1 0 nbit 4 nbit 5 0 0 x x 1 1 nbit 4 nbit 5 bit 6 motor enable 2 the mtr2 disk interface output is not supported in the LPC47M15X. bit 7 motor enable 3 the mtr3 disk interface output is not supported in the LPC47M15X. tape drive register (tdr) address 3f3 read/write the tape drive register (tdr) is included for 82077 software compatibility and allows the user to assign tape support to a particular drive during init ialization. any future references to that drive automatically invokes tape support. the tdr tape select bits tdr.[1:0] determine the tape drive number. table 5 illustrates the tape select bit encoding. note that drive 0 is t he boot device and cannot be assigned tape support. the remaining tape drive register bits tdr.[7:2] are tristated when re ad. the tdr is unaffected by a software reset. table 5 ? tape select bits tape sel1 (tdr.1) tape sel0 (tdr.0) drive selected 0 0 1 1 0 1 0 1 none 1 2 3 normal floppy mode normal mode.register 3f3 contains only bits 0 and 1. when this register is read, bits 2 ? 7 are ?0?. db7 db6 db5 db4 db3 db2 db1 db0 reg 3f3 0 0 0 0 0 0 tape sel1 tape sel0 enhanced floppy mode 2 (os2) register 3f3 for enhanced floppy mode 2 operation. db7 db6 db5 db4 db3 db2 db1 db0 reg 3f3 reserved reserved drive type id floppy boot drive tape sel1 tape sel0
smsc ds ? LPC47M15X page 35 rev. 08/02/2001 table 6 ? drive type id digital output register register 3f3 ? drive type id bit 1 bit 0 bit 5 bit 4 0 0 l0-crf2 ? b1 l0-crf2 ? b0 0 1 l0-crf2 ? b3 l0-crf2 ? b2 1 0 l0-crf2 ? b5 l0-crf2 ? b4 1 1 l0-crf2 ? b7 l0-crf2 ? b6 note: l0-crf2-bx = logical device 0, c onfiguration register f2, bit x. data rate select register (dsr) address 3f4 write only this register is write only. it is used to program the data rate, amount of write precom pensation, power down status, and software reset. the data rate is programmed using the configuration control regist er (ccr) not the dsr, for pc/at and ps/2 model 30. 7 6 5 4 3 2 1 0 s/w reset power down 0 pre- comp2 pre- comp1 pre- comp0 drate sel1 drate sel0 reset cond. 0 0 0 0 0 0 1 0 this register is write only. it is used to program the data rate, amount of write precom pensation, power down status, and software reset. the data rate is programmed using the configuration control regist er (ccr) not the dsr, for pc/at and ps/2 model 30. other applications can set the data rate in the dsr. the data rate of the floppy controller is the most recent write of either the dsr or ccr. the dsr is unaffected by a software reset. a hardware reset will set the dsr to 02h, which corresponds to the default precom pensation setting and 250 kbps. bit 0 and 1 data rate select these bits control the data rate of the floppy controller. see table 8 for the settings corresponding to the individual data rates. the data rate select bits are unaffected by a software reset, and are set to 250 kbps after a hardware reset. bit 2 through 4 precompensation select these three bits select the value of wr ite precompensation that will be applie d to the wdata output signal. table 7 shows the precompensation values for t he combination of these bits settings. track 0 is the default starting track number to start precompensation. this starting tr ack number can be changed by the configure command. table 7 ? precompensation delays precomp 432 precompensation delay (nsec) <2mbps 2mbps 111 001 010 011 100 101 110 000 0.00 41.67 83.34 125.00 166.67 208.33 250.00 default 0 20.8 41.7 62.5 83.3 104.2 125 default default: see table 10
smsc ds ? LPC47M15X page 36 rev. 08/02/2001 bit 5 undefined should be written as a logic ?0?. bit 6 low power a logic ?1? written to this bit will put the floppy controller into manual low power mode. the floppy controller clock and data separator circuits will be turned off. the controller will come out of manual low power mode after a software reset or access to the data regi ster or main status register. bit 7 software reset this active high bit has the same function as the dor rese t (dor bit 2) except that this bit is self clearing. note: the dsr is shadowed in the floppy data rate select shadow register, located at the offset 0x1f in the runtime register block separator ci rcuits will be turned off. the contro ller will come out of manual low power. table 8 ? data rates drive rate data rate data rate drate(1) drt1 drt0 sel1 sel0 mfm fm densel 1 0 0 0 1 1 1meg --- 1 1 1 0 0 0 0 500 250 1 0 0 0 0 0 1 300 150 0 0 1 0 0 1 0 250 125 0 1 0 0 1 1 1 1meg --- 1 1 1 0 1 0 0 500 250 1 0 0 0 1 0 1 500 250 0 0 1 0 1 1 0 250 125 0 1 0 1 0 1 1 1meg --- 1 1 1 1 0 0 0 500 250 1 0 0 1 0 0 1 2meg --- 0 0 1 1 0 1 0 250 125 0 1 0 drive rate table (recommended) 00 = 360k, 1.2m, 720k, 1.44m and 2.88m vertical format 01 = 3-mode drive 10 = 2 meg tape note 1: the drate and densel values are mapped onto the drvden pins. table 9 ? drvden mapping dt1 dt0 drvden1 (1) drvden0 (1) drive type 0 0 drate0 densel 4/2/1 mb 3.5? 2/1 mb 5.25? fdds 2/1.6/1 mb 3.5? (3-mode) 1 0 drate0 drate1 0 1 drate0 ndensel ps/2 1 1 drate1 drate0
smsc ds ? LPC47M15X page 37 rev. 08/02/2001 table 10 ? default precompensation delays data rate precompensation delays 2 mbps 1 mbps 500 kbps 300 kbps 250 kbps 20.8 ns 41.67 ns 125 ns 125 ns 125 ns main status register address 3f4 read only the main status register is a read-only register and indi cates the status of the disk controller. the main status register can be read at any time. the msr indicates when the disk controller is ready to receive data via the data register. it should be read before each byte transferring to or from the data register except in dma mode. no delay is required when reading the msr after a data transfer. 7 6 5 4 3 2 1 0 rqm dio non dma cmd busy reserved reserved drv1 busy drv0 busy bit 0 ? 1 drv x busy these bits are set to 1s when a drive is in the seek por tion of a command, including implied and overlapped seeks and recalibrates. bit 4 command busy this bit is set to a 1 when a command is in progress. this bit will go active after the command byte has been accepted and goes inactive at the end of the results phase. if there is no result phase (seek, recalibrate commands), this bit is returned to a 0 after the last command byte. bit 5 non-dma reserved, read ?0?. this part does not support non-dma mode. bit 6 dio indicates the direction of a data transfer once a rqm is set. a 1 indicates a read and a 0 indicates a write is required. bit 7 rqm indicates that the host can transfer data if set to a 1. no access is permitted if set to a 0. data register (fifo) address 3f5 read/write all command parameter information, disk data and result st atus are transferred between the host processor and the floppy disk controller through the data register. data transfers are governed by the rqm and dio bits in the main status register. the data register defaults to fifo disabled mode a fter any form of reset. this maintains pc/at hardware compatibility. the default values can be changed throug h the configure command (enable full fifo operation with threshold control). the advantage of the fifo is that it allows the system a larger dma latency without causing a disk error. table 11 gives several examples of the delays with a fifo. the data is based upon the following formula: threshold # x 1 data rate x 8 - 1.5 us = delay
smsc ds ? LPC47M15X page 38 rev. 08/02/2001 at the start of a command, the fifo action is always disabled and command parameters must be sent based upon the rqm and dio bit settings. as the command execution phase is entered, the fifo is cleared of any data to ensure that invalid data is not transferred. an overrun or underrun will terminate the current command an d the transfer of data. disk writes will complete the current sector by generating a 00 patte rn and valid crc. reads require the host to remove the remaining data so that the result phase may be entered. table 11 ? fifo service delay fifo threshold examples maximum delay to servicing at 2 mbps data rate 1 byte 2 bytes 8 bytes 15 bytes 1 x 4 us - 1.5 us = 2.5 us 2 x 4 us - 1.5 us = 6.5 us 8 x 4 us - 1.5 us = 30.5 us 15 x 4 us - 1.5 us = 58.5 us fifo threshold examples maximum delay to servicing at 1 mbps data rate 1 byte 2 bytes 8 bytes 15 bytes 1 x 8 us - 1.5 us = 6.5 us 2 x 8 us - 1.5 us = 14.5 us 8 x 8 us - 1.5 us = 62.5 us 15 x 8 us - 1.5 us = 118.5 us fifo threshold examples maximum delay to servicing at 500 kbps data rate 1 byte 2 bytes 8 bytes 15 bytes 1 x 16 us - 1.5 us = 14.5 us 2 x 16 us - 1.5 us = 30.5 us 8 x 16 us - 1.5 us = 126.5 us 15 x 16 us - 1.5 us = 238.5 us digital input register (dir) address 3f7 read only this register is read-only in all modes. pc-at mode 7 6 5 4 3 2 1 0 dsk chg 0 0 0 0 0 0 0 reset cond. n/a n/a n/a n/a n/a n/a n/a n/a bit 0 ? 6 undefined the data bus outputs d0 ? 6 are read as ?0?. bit 7 dskchg this bit monitors the pin of the same name and reflec ts the opposite value seen on the disk cable or the value programmed in the force disk change register (see runtime register at offset 0x1e).
smsc ds ? LPC47M15X page 39 rev. 08/02/2001 ps/2 mode 7 6 5 4 3 2 1 0 dsk chg 1 1 1 1 drate sel1 drate sel0 nhigh dens reset cond. n/a n/a n/a n/a n/a n/a n/a 1 bit 0 nhigh dens this bit is low whenever the 500 kbps or 1 mbps data rates are selected, and high when 250 kbps and 300 kbps are selected. bits 1 ? 2 data rate select these bits control the data rate of the floppy controller. see table 8 for the settings corresponding to the individual data rates. the data rate select bits are unaffected by a software reset, and are set to 250 kbps after a hardware reset. bits 3 ? 6 undefined always read as a logic ?1? bit 7 dskchg this bit monitors the pin of the same name and reflec ts the opposite value seen on the disk cable or the value programmed in the force disk change register (see runtime register at offset 0x1e). model 30 mode 7 6 5 4 3 2 1 0 dsk chg 0 0 0 dmaen noprec drate sel1 drate sel0 reset cond. n/a 0 0 0 0 0 1 0 bits 0 ? 1 data rate select these bits control the data rate of the floppy controller. see table 8 for the settings corresponding to the individual data rates. the data rate select bits are unaffected by a software reset, and are set to 250 kbps after a hardware reset. bit 2 noprec this bit reflects the value of no prec bit set in the ccr register. bit 3 dmaen this bit reflects the value of dmaen bit set in the dor register bit 3. bits 4 ? 6 undefined always read as a logic ?0? bit 7 dskchg this bit monitors the pin of the same name and reflec ts the opposite value seen on the disk cable or the value programmed in the force disk change register (see runtime register at offset 0x1e).
smsc ds ? LPC47M15X page 40 rev. 08/02/2001 configuration control register (ccr) address 3f7 write only pc/at and ps/2 modes 7 6 5 4 3 2 1 0 0 0 0 0 0 0 drate sel1 drate sel0 reset cond. n/a n/a n/a n/a n/a n/a 1 0 bit 0 and 1 data rate select 0 and 1 these bits determine the data rate of the floppy c ontroller. see table 8 for the appropriate values. bit 2 ? 7 reserved should be set to a logical ?0? ps/2 model 30 mode 7 6 5 4 3 2 1 0 0 0 0 0 0 noprec drate sel1 drate sel0 reset cond. n/a n/a n/a n/a n/a n/a 1 0 bit 0 and 1 data rate select 0 and 1 these bits determine the data rate of the floppy c ontroller. see table 8 for the appropriate values. bit 2 no precompensation this bit can be set by software, but it has no functionality. it can be read by bit 2 of the dsr when in model 30 register mode. unaffected by software reset. bit 3 ? 7 reserved should be set to a logical ?0? table 9 shows the state of the densel pin. the densel pin is set high after a hardware reset and is unaffected by the dor and the dsr resets. 6.4.2 status register encoding during the result phase of certain commands, the data regi ster contains data bytes that give the status of the command just executed.
smsc ds ? LPC47M15X page 41 rev. 08/02/2001 table 12 ? status register 0 bit no. symbol name description 7,6 ic interrupt code 00 - normal termination of command. the specified command was properly executed and completed without error. 01 - abnormal termination of command. command execution was started, but was not successfully completed. 10 - invalid command. the requested command could not be executed. 11 - abnormal termination caused by polling. 5 se seek end the fdc completed a seek, relative seek or recalibrate command (used during a sense interrupt command). 4 ec equipment check the trk0 pin failed to become a "1" after: 1. 80 step pulses in the recalibrate command. 2. the relative seek command caused the fdc to step outward beyond track 0. 3 unused. this bit is always "0". 2 h head address the current head address. 1,0 ds1,0 drive select the current selected drive. table 13 ? status register 1 bit no. symbol name description 7 en end of cylinder the fdc tried to access a sector beyond the final sector of the track (255d). will be set if tc is not issued after read or write data command. 6 unused. this bit is always "0". 5 de data error the fdc detected a crc error in either the id field or the data field of a sector. 4 or overrun/ underrun becomes set if the fdc does not receive cpu or dma service within the required time interval, resulting in data overrun or underrun. 3 unused. this bit is always "0". 2 nd no data any one of the following: 1. read data, read deleted data command - the fdc did not find the specified sector. 2. read id command - the fdc cannot read the id field without an error. 3. read a track command - the fdc cannot find the proper sector sequence. 1 nw not writeable wp pin became a "1" while the fdc is executing a write data, write deleted data, or format a track command. 0 ma missing address mark any one of the following: 1. the fdc did not detect an id address mark at the specified track after encountering the index pulse from the nindex pin twice. 2. the fdc cannot detect a data address mark or a deleted data address mark on the specified track. table 14 ? status register 2 bit no. symbol name description 7 unused. this bit is always "0". 6 cm control mark any one of the following: read data command - the fdc encountered a deleted
smsc ds ? LPC47M15X page 42 rev. 08/02/2001 bit no. symbol name description data address mark. read deleted data command - the fdc encountered a data address mark. 5 dd data error in data field the fdc detected a crc error in the data field. 4 wc wrong cylinder the track address from the sector id field is different from the track address maintained inside the fdc. 3 unused. this bit is always "0". 2 unused. this bit is always "0". 1 bc bad cylinder the track address from the sector id field is different from the track address maintained inside the fdc and is equal to ff hex, which indicates a bad track with a hard error according to the ibm soft-sectored format. 0 md missing data address mark the fdc cannot detect a data address mark or a deleted data address mark. table 15 ? status register 3 bit no. symbol name description 7 unused. this bit is always "0". 6 wp write protected indicates the status of the wrtprt pin. 5 unused. this bit is always "1". 4 t0 track 0 indicates the status of the trk0 pin. 3 unused. this bit is always "1". 2 hd head address indicates the status of the hdsel pin. 1,0 ds1,0 drive select indicates the status of the ds1, ds0 pins. reset there are three sources of system rese t on the fdc: the npci_r eset pin, a reset generated via a bit in the dor, and a reset generated via a bit in the dsr. at power on, a power on reset initializes the fdc. all resets take the fdc out of the power down state. all operations are terminated upon a npci _reset, and the fdc enters an idle state. a reset while a disk write is in progress will corrupt the data and crc. on exiting the reset state, various internal registers are cleared, including the config ure command information, and the fdc waits for a new command. drive polling will start unless disabled by a new configure command. npci_reset pin (hardware reset) the npci_reset pin is a global reset and clears all registers except those programmed by the specify command. the dor reset bit is enabled and must be cleared by the host to exit the reset state. dor reset vs. dsr reset (software reset) these two resets are functionally the same. both will rese t the fdc core, which affects drive status information and the fifo circuits. the dsr reset clears itself automatically wh ile the dor reset requires the host to manually clear it. dor reset has precedence over the dsr reset. the dor reset is set automatically upon a pin reset. the user must manually clear this reset bit in the dor to exit the reset state. modes of operation the fdc has three modes of operation, pc/at mode, ps/2 mode and model 30 mode. these are determined by the state of the interface mode bits in ld0-crf0[3,2]. pc/at mode the pc/at register set is enabled, the dma enable bit of the dor becomes valid (controls the interrupt and dma functions), and densel is an active high signal.
smsc ds ? LPC47M15X page 43 rev. 08/02/2001 ps/2 mode this mode supports the ps/2 models 50/60 /80 configuration and register set. the dma bit of the dor becomes a ?don?t care?. the dma and interrupt functions are always enabled, and densel is active low. model 30 mode this mode supports ps/2 model 30 configuration and regist er set. the dma enable bit of the dor becomes valid (controls the interrupt and dma functi ons), and densel is active low. dma transfers dma transfers are enabled with the specify command and are initiated by the fdc by activating a dma request cycle. dma read, write and verify cycles are suppor ted. the fdc supports two dma transfer modes: single transfer and burst transfer. burst mode is enabled via logical device 0-crf0-bit[1] (ld0-crf0[1]). controller phases for simplicity, command handling in the fdc can be divid ed into three phases: command, execution, and result. each phase is described in the following sections. command phase after a reset, the fdc enters the command phase and is read y to accept a command from the host. for each of the commands, a defined set of command code bytes and para meter bytes has to be writt en to the fdc before the command phase is complete. (please refer to table 16 for the command set descriptions). these bytes of data must be transferred in the order prescribed. before writing to the fdc, the host must examine the rqm and dio bits of the main status register. rqm and dio must be equal to ?1? and ?0? respectively before command bytes may be written. rqm is set false by the fdc after each write cycle until the received byte is processed. the fdc asserts rqm again to request each parameter byte of the command unless an illegal command condition is detec ted. after the last paramet er byte is received, rqm remains ?0? and the fdc automatically enters the next phase as defined by the command definition. the fifo is disabled during the command phase to pr ovide for the proper handling of the ?invalid command? condition. execution phase all data transfers to or from the fdc occur during the exec ution phase, which can proceed in dma as indicated in the specify command. after a reset, the fifo is disabled. each data byte is transferred by a read/write or dma cycle depending on the dma mode. the configure command can enable the fifo and set the fifo threshold value. the following paragraphs detail the operation of the fifo flow control. in these descriptions, is defined as the number of bytes available to the fdc when service is requested from the host and ranges from 1 to 16. the parameter fifothr, which the user program s, is one less and ranges from 0 to 15. a low threshold value (i.e. 2) results in longer periods of time between service requests, but requires faster servicing of the request for both read and write cases. the host reads (writes) from (to) the fifo until empty (full), then the transfer request goes inactive. the host must be very respon sive to the service request. this is the desired case for use with a ?fast? system. a high value of threshold (i.e. 12) is used with a ?sluggish? system by affording a long latency period after a service request, but results in more frequent service requests. non-dma mode ? transfers from the fifo to the host this part does not support non-dma mode. non-dma mode ? transfers from the host to the fifo this part does not support non-dma mode. dma mode ? transfers from the fifo to the host the fdc generates a dma request cycle when the fifo contains (16 - ) bytes, or the last byte of a full sector transfer has been placed in the fifo. the dma contro ller must respond to the request by reading data from
smsc ds ? LPC47M15X page 44 rev. 08/02/2001 the fifo. the fdc will deactivate the dma request when t he fifo becomes empty by gen erating the proper sync for the data transfer. dma mode ? transfers from the host to the fifo. the fdc generates a dma request cycle when entering the execution phase of the data transfer commands. the dma controller must respond by placing data in the fifo. the dma request remains active until the fifo becomes full. the dma request cycle is reasserted when the fifo has bytes remaining in the fifo. the fdc will terminate the dma cycle after a tc, indica ting that no more data is required. data transfer termination the fdc supports terminal count explicitly through the tc pin and implicitly through the underrun/overrun and end- of-track (eot) functions. for full sector transfers, the eot parameter can define the last sector to be transferred in a single or multi-sector transfer. if the last sector to be transferred is a partial sector, the host can stop transferring the data in mid-sector, and the fdc will continue to complete the sector as if a tc cy cle was received. the only difference between these implicit functions and tc cycle is that they return ?abnormal term ination? result status. su ch status indications can be ignored if they were expected. note that when the host is sending data to the fifo of the fdc, the internal sector count will be complete when the fdc reads the last byte from its side of the fifo. there ma y be a delay in the removal of the transfer request signal of up to the time taken for the fdc to read the last 16 by tes from the fifo. the host must tolerate this delay. result phase the generation of the interrupt determines the beginning of the result phase. for each of the commands, a defined set of result bytes has to be read from the fdc before th e result phase is complete. these bytes of data must be read out for another command to start. rqm and dio must both equal ?1? before the result bytes may be read. after all the result bytes have been read, the rqm and dio bits switch to ?1? and ?0? respectively, and the cb bit is cleared, indicating that the fdc is ready to accept the next command. command set/descriptions commands can be written whenever the fdc is in the co mmand phase. each command has a unique set of needed parameters and status results. the fdc checks to see that the first byte is a valid command and, if valid, proceeds with the command. if it is invalid, an interrupt is is sued. the user sends a sense interrupt status command which returns an invalid command error. refer to table 16 for explanations of the various symbols used. table 17 lists the required parameters and the results associated with each command that the fdc is capable of performing.
smsc ds ? LPC47M15X page 45 rev. 08/02/2001 table 16 ? description of command symbols symbol name description c cylinder address the currently selected address; 0 to 255. d data pattern the pattern to be written in each sector data field during formatting. d0, d1 drive select 0-1 designates which drives are pe rpendicular drives on the perpendicular mode command. a ?1? indicates a perpendicular drive. dir direction control if this bit is 0, then the head will step out from the spindle during a relative seek. if set to a 1, the head will step in toward the spindle. ds0, ds1 disk drive select ds 1 ds0 drive 0 0 drive 0 0 1 drive 1 dtl special sector size by setting n to zero (00), dtl may be used to control the number of bytes transferred in disk read/write commands. the sector size (n = 0) is set to 128. if the actual sector (on the diskette) is larger than dtl, the remainder of the actual sector is read but is not passed to the host during read commands; during write commands, the remainder of the actual sector is written with all zero bytes. the crc check code is calculated with the actual sector. when n is not zero, dtl has no meaning and should be set to ff hex. ec enable count when this bit is ?1? the ?dtl? parameter of the verify command becomes sc (number of sectors per track). efifo enable fifo this active low bit when a 0, enables the fifo. a ?1? disables the fifo (default). eis enable implied seek when set, a seek operation will be performed before executing any read or write command that requires the c parameter in the command phase. a ?0? disables the implied seek. eot end of track the final sector number of the current track. gap alters gap 2 length when using perpendicular mode. gpl gap length the gap 3 size. (gap 3 is the space between sectors excluding the vco synchronization field). h/hds head address selected head: 0 or 1 (disk side 0 or 1) as encoded in the sector id field. hlt head load time the time interval that fdc waits after loading the head and before initializing a read or write operation. refer to the specify command for actual delays. hut head unload time the time interval from the end of the execution phase (of a read or write command) until the head is unloaded. refer to the specify command for actual delays. lock lock defines whether efifo, fifothr, and pretrk parameters of the configure command can be reset to their default values by a ?software reset?. (a reset caused by writing to the appropriate bits of either the dsr or dor) mfm mfm/fm mode selector a one selects the double density (mfm) mode. a zero selects single density (fm) mode. mt multi-track selector when set, this flag selects the multi-track operating mode. in this mode, the fdc treats a complete cylinder under head 0 and 1 as a single track. the fdc operates as this expanded track started at the first sector under head 0 and ended at the last sector under head 1. with this flag set, a multitrack read or write operation will automatically continue to the first sector under head 1 when the fdc finishes operating on the last sector under head 0.
smsc ds ? LPC47M15X page 46 rev. 08/02/2001 table 16 ? description of command symbols symbol name description n sector size code this specifies the number of bytes in a sector. if this parameter is "00", then the sector size is 128 bytes. the number of bytes transferred is determined by the dtl parameter. otherwise the sector size is (2 raised to the "n'th" power) times 128. all values up to "07" hex are allowable. "07"h would equal a sector size of 16k. it is the user's responsibility to not select combinations that are not possible with the drive. n sector size 00 128 bytes 01 256 bytes 02 512 bytes 03 1024 bytes ? ? 07 16k bytes ncn new cylinder number the desired cylinder number. nd non-dma mode flag write ?0?. this part does not support non-dma mode. ow overwrite the bits d0-d3 of the perpendicular mode command can only be modified if ow is set to 1. ow id defined in the lock command. pcn present cylinder number the current position of the head at the completion of sense interrupt status command. poll polling disable when set, the internal polling routine is disabled. when clear, polling is enabled. pretrk precompensation start track number programmable from track 00 to ffh. r sector address the sector number to be read or written. in multi-sector transfers, this parameter specifies the sector number of the first sector to be read or written. rcn relative cylinder number relative cylinder offset from present cylinder as used by the relative seek command. sc number of sectors per track the number of sectors per track to be initialized by the format command. the number of sectors per track to be verified during a verify command when ec is set. sk skip flag when set to 1, sectors containing a deleted data address mark will automatically be skipped during the execution of read data. if read deleted is executed, only sectors with a deleted address mark will be accessed. when set to ?0?, the sector is read or written the same as the read and write commands. srt step rate interval the time interval between step pulses issued by the fdc. programmable from 0.5 to 8 milliseconds in increments of 0.5 ms at the 1 mbit data rate. refer to the specify command for actual delays. st0 st1 st2 st3 status 0 status 1 status 2 status 3 registers within the fdc which store status information after a command has been executed. this status information is available to the host during the result phase after command execution. wgate write gate alters timing of we to allow for pre-erase loads in perpendicular drives.
smsc ds ? LPC47M15X page 47 rev. 08/02/2001 6.4.3 instruction set table 17 ? instruction set read data data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w mt mfm sk 0 0 1 1 0 command codes w 0 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl execution data transfer between the fdd and system. result r st0 status information after com- mand execution. r st1 r st2 r c sector id information after command execution. r h r r r n read deleted data data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w mt mfm sk 0 1 1 0 0 command codes w 0 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl execution data transfer between the fdd and system. result r st0 status information after com- mand execution. r st1 r st2 r c sector id information after command execution. r h r r r n
smsc ds ? LPC47M15X page 48 rev. 08/02/2001 write data data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w mt mfm 0 0 0 1 0 1 command codes w 0 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl execution data transfer between the fdd and system. result r st0 status information after com- mand execution. r st1 r st2 r c sector id information after command execution. r h r r r n write deleted data data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w mt mfm 0 0 1 0 0 1 command codes w 0 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl execution data transfer between the fdd and system. result r st0 status information after command execution. r st1 r st2 r c sector id information after command execution. r h r r r n
smsc ds ? LPC47M15X page 49 rev. 08/02/2001 read a track data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 mfm 0 0 0 0 1 0 command codes w 0 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl execution data transfer between the fdd and system. fdc reads all of cylinders? contents from index hole to eot. result r st0 status information after command execution. r st1 r st2 r c sector id information after command execution. r h r r r n verify data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w mt mfm sk 1 0 1 1 0 command codes w ec 0 0 0 0 hds ds1 ds0 w c sector id information prior to command execution. w h w r w n w eot w gpl w dtl/sc execution no data transfer takes place. result r st0 status information after command execution. r st1 r st2 r c sector id information after command execution. r h r r r n
smsc ds ? LPC47M15X page 50 rev. 08/02/2001 version data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 1 0 0 0 0 command code result r 1 0 0 1 0 0 0 0 enhanced controller format a track data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 mfm 0 0 1 1 0 1 command codes w 0 0 0 0 0 hds ds1 ds0 w n bytes/sector w sc sectors/cylinder w gpl gap 3 w d filler byte execution for each sector repeat: w c input sector parameters w h w r w n fdc formats an entire cylinder result r st0 status information after command execution r st1 r st2 r undefined r undefined r undefined r undefined recalibrate data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 0 1 1 1 command codes w 0 0 0 0 0 0 ds1 ds0 execution head retracted to track 0 interrupt. sense interrupt status data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 1 0 0 0 command codes result r st0 status information at the end of each seek operation. r pcn
smsc ds ? LPC47M15X page 51 rev. 08/02/2001 specify data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 0 0 1 1 command codes w srt hut w hlt nd sense drive status data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 0 1 0 0 command codes w 0 0 0 0 0 hds ds1 ds0 result r st3 status information about fdd seek data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 1 1 1 1 command codes w 0 0 0 0 0 hds ds1 ds0 w ncn execution head positioned over proper cylinder on diskette. configure data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 1 0 0 1 1 configure information w 0 0 0 0 0 0 0 0 w 0 eis efifo poll fifothr execution w pretrk relative seek data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 1 dir 0 0 1 1 1 1 w 0 0 0 0 0 hds ds1 ds0 w rcn
smsc ds ? LPC47M15X page 52 rev. 08/02/2001 dumpreg data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 0 1 1 1 0 *note: registers placed in fifo execution result r pcn-drive 0 r pcn-drive 1 r pcn-drive 2 r pcn-drive 3 r srt hut r hlt nd r sc/eot r lock 0 d3 d2 d1 d0 gap wgate r 0 eis efifo poll fifothr r pretrk read id data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 mfm 0 0 1 0 1 0 commands w 0 0 0 0 0 hds ds1 ds0 execution the first correct id information on the cylinder is stored in data register result r st0 status information after command execution. disk status after the command has completed r st1 r st2 r c r h r r r n perpendicular mode data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w 0 0 0 1 0 0 1 0 command codes ow 0 d3 d2 d1 d0 gap wgate
smsc ds ? LPC47M15X page 53 rev. 08/02/2001 invalid codes data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w invalid codes invalid command codes (noop ? fdc goes into standby state) result r st0 st0 = 80h lock data bus phase r/w d7 d6 d5 d4 d3 d2 d1 d0 remarks command w lock 0 0 1 0 1 0 0 command codes result r 0 0 0 lock 0 0 0 0 sc is returned if the last command that was issued was the format command. eot is returned if the last command was a read or write. note: these bits are used internally only. they are not reflected in the drive select pins. it is the user?s responsibility to maintain correspondence between these bits and the drive select pins (dor). 6.4.4 data transfer commands all of the read data, write data and verify type comma nds use the same parameter bytes and return the same results information, the only difference bein g the coding of bits 0-4 in the first byte. an implied seek will be executed if the feature was enab led by the configure command. this seek is completely transparent to the user. the drive busy bit for the drive w ill go active in the main status register during the seek portion of the command. if the seek portion fails, it is reflected in the results status normally returned for a read/write data command. status register 0 (st0) would contain the error code and c would contain the cylinder on which the seek failed. read data a set of nine (9) bytes is required to place the fdc in the read data mode. after the read data command has been issued, the fdc loads the head (if it is in the unloaded stat e), waits the specified head se ttling time (defined in the specify command), and begins reading id address marks an d id fields. when the sector address read off the diskette matches with the sector address specified in the command, the fdc reads the sector?s data field and transfers the data to the fifo. after completion of the read operation from the current sector, the sector addr ess is incremented by one and the data from the next logical sector is read and output via the fifo. this contin uous read function is called ?multi-sector read operation?. upon receipt of the tc cycle, or an implied tc (fifo overrun/underrun), the fdc stops sending data but will continue to read data from the current se ctor, check the crc bytes, and at the end of the sector, terminate the read data command. n determines the number of bytes per sector (see table 18 below). if n is set to zero, the sector size is set to 128. the dtl value determines the number of bytes to be transf erred. if dtl is less than 128, the fdc transfers the specified number of bytes to the host. for reads, it cont inues to read the entire 128-byte sector and checks for crc errors. for writes, it completes the 128-byte sector by filli ng in zeros. if n is not set to 00 hex, dtl should be set to ff hex and has no impact on the number of bytes transferred. table 18 ? sector sizes n sector size 00 01 02 03 .. 07 128 bytes 256 bytes 512 bytes 1024 bytes ? 16 kbytes
smsc ds ? LPC47M15X page 54 rev. 08/02/2001 the amount of data which can be handled with a single co mmand to the fdc depends upon mt (multi-track) and n (number of bytes/sector). the multi-track function (mt) allows the fdc to read data from both sides of the diskette. for a particular cylinder, data will be transferred starting at sect or 1, side 0 and completing the last se ctor of the same track at side 1. if the host terminates a read or write operation in the fdc, the id information in the result phase is dependent upon the state of the mt bit and eot byte. refer to table 19. at the completion of the read data command, the head is not unloaded until after the head unload time interval (specified in the specify command) has elapsed. if the ho st issues another command before the head unloads, then the head settling time may be saved between subsequent reads. if the fdc detects a pulse on the nindex pin twice without finding the specified sector (meaning that the diskette?s index hole passes through index detect logic in the drive twice) , the fdc sets the ic code in status register 0 to ?01? indicating abnormal termination, sets the nd bit in st atus register 1 to ?1? indi cating a sector not found, and terminates the read data command. after reading the id and data fields in each sector, the fdc checks the crc bytes. if a crc error occurs in the id or data field, the fdc sets the ic code in status register 0 to ?01? indicating abnormal termination, sets the de bit flag in status register 1 to ?1?, sets the dd bit in status register 2 to ?1? if crc is incorrect in the id field, and terminates the read data command. table 20 describes the effect of the sk bit on the read data command execution and results. except where noted in table 20, the c or r value of the sect or address is automatically incremented (see table 22). table 19 ? effects of mt and n bits mt n maximum transfer capacity final sector read from disk 0 1 0 1 0 1 1 1 2 2 3 3 256 x 26 = 6,656 256 x 52 = 13,312 512 x 15 = 7,680 512 x 30 = 15,360 1024 x 8 = 8,192 1024 x 16 = 16,384 26 at side 0 or 1 26 at side 1 15 at side 0 or 1 15 at side 1 8 at side 0 or 1 16 at side 1 table 20 ? skip bit vs read data command results sk bit value data address mark type encountered sector read? cm bit of st2 set? description of results 0 0 1 1 normal data deleted data normal data deleted data yes yes yes no no yes no yes normal termination. address not incremented. next sector not searched for. normal termination. normal termination. sector not read (?skipped?). read deleted data this command is the same as the read data command, onl y it operates on sectors t hat contain a deleted data address mark at the beginning of a data field.
smsc ds ? LPC47M15X page 55 rev. 08/02/2001 table 21 describes the effect of the sk bit on the read de leted data command execution and results. except where noted in table 21, the c or r value of the sector address is automatic ally incremented (see table 22). table 21 ? skip bit vs. read deleted data command results sk bit value data address mark type encountered sector read? cm bit of st2 set? description of results 0 0 1 1 normal data deleted data normal data deleted data yes yes no yes yes no yes no address not incremented. next sector not searched for. normal termination. normal termination. sector not read (?skipped?). normal termination. read a track this command is similar to the read data command except t hat the entire data field is read continuously from each of the sectors of a track. immediately after encountering a pulse on the ni ndex pin, the fdc starts to read all data fields on the track as continuous blocks of data without rega rd to logical sector numbers. if the fdc finds an error in the id or data crc check bytes, it continues to read data from the track and sets the appropriate error bits at the end of the command. the fdc compares the id information read from each sector with the specified value in the command and sets the nd flag of status register 1 to a ?1 ? if there no comparison. mult i-track or skip operations are not allowed with this command. the mt and sk bits (bits d7 and d5 of the first command byte respectively) should always be set to ?0?. this command terminates when the eot specified number of sectors has not been read. if the fdc does not find an id address mark on the diskette after the second occurrence of a pulse on the nindex pin, then it sets the ic code in status register 0 to ?01? (abnormal termination), sets the ma bit in status register 1 to ?1?, and terminates the command. table 22 ? result phase table mt head final sector transferred to id information at result phase host c h r n 0 0 less than eot nc nc r + 1 nc equal to eot c + 1 nc 01 nc 1 less than eot nc nc r + 1 nc equal to eot c + 1 nc 01 nc 1 0 less than eot nc nc r + 1 nc equal to eot nc lsb 01 nc 1 less than eot nc nc r + 1 nc equal to eot c + 1 lsb 01 nc nc: no change, the same value as the o ne at the beginning of command execution. lsb: least significant bit, the lsb of h is complemented. write data after the write data command has been issued, the fdc l oads the head (if it is in the unloaded state), waits the specified head load time if unloaded (defined in the specif y command), and begins reading id fields. when the sector
smsc ds ? LPC47M15X page 56 rev. 08/02/2001 address read from the diskette matches the sector address specified in the command, the fdc reads the data from the host via the fifo and writes it to the sector?s data field. after writing data into the current se ctor, the fdc computes the crc value and writes it into the crc field at the end of the sector transfer. the sector numb er stored in ?r? is incremented by one, and the fdc continues writing to the next data field. the fdc continues this ?multi-sector write operation?. upon rece ipt of a terminal count signal or if a fifo over/under run occurs while a data field is being written, then the remainder of the data field is filled with zeros. the fdc reads the id field of each sector and checks the crc bytes. if it detects a crc error in one of the id fields, it sets the ic code in status register 0 to ?01? (abnormal te rmination), sets the de bit of st atus register 1 to ?1?, and terminates the write data command. the write data command operates in much the same man ner as the read data command. the following items are the same. please refer to the read data command for details: transfer capacity en (end of cylinder) bit nd (no data) bit head load, unload time interval id information when the host terminates the command definition of dtl when n = 0 and when n does not = 0 write deleted data this command is almost the same as the write data command except that a deleted data address mark is written at the beginning of the data field instead of the normal data address mark. this command is typically used to mark a bad sector containing an error on the floppy disk. verify the verify command is used to verify the data stored on a disk. this command acts exactly like a read data command except that no data is transferred to the hos t. data is read from the disk and crc is computed and checked against the previously-stored value. because data is not transferred to the host, the tc cycle cannot be used to terminate this command. by setting the ec bit to ?1?, an implicit tc will be issued to the fdc. this implicit tc will occur when the sc value has decremented to 0 (an sc value of 0 will verify 256 se ctors). this command can also be terminated by setting the ec bit to ?0? and the eot value equal to the final sector to be checked. if ec is set to ?0?, dtl/sc should be programmed to 0ffh. refer to table 22 and table 23 for information concerning the values of mt and ec versus sc and eot value. definitions: # sectors per side = number of formatt ed sectors per each side of the disk. # sectors remaining = number of formatted sectors left which can be read, including side 1 of the disk if mt is set to ?1?.
smsc ds ? LPC47M15X page 57 rev. 08/02/2001 table 23 ? verify command result phase table mt ec sc/eot value termination result 0 0 sc = dtl eot <= # sectors per side success termination result phase valid 0 0 sc = dtl eot > # sectors per side unsuccessful termination result phase invalid 0 1 sc <= # sectors remaining and eot <= # sectors per side successful termination result phase valid 0 1 sc > # sectors remaining or eot > # sectors per side unsuccessful termination result phase invalid 1 0 sc = dtl eot <= # sectors per side successful termination result phase valid 1 0 sc = dtl eot > # sectors per side unsuccessful termination result phase invalid 1 1 sc <= # sectors remaining and eot <= # sectors per side successful termination result phase valid 1 1 sc > # sectors remaining or eot > # sectors per side unsuccessful termination result phase invalid note: if mt is set to ?1? and the sc value is greater than the number of remaining formatted sectors on side 0, verifying will continue on side 1 of the disk. format a track the format command allows an entire track to be formatted. after a pulse from the nindex pin is detected, the fdc starts writing data on the disk including gaps, address mar ks, id fields, and data fields per the ibm system 34 or 3740 format (mfm or fm respectively). the particular va lues that will be written to the gap and data field are controlled by the values programmed into n, sc, gpl, and d which are specified by the host during the command phase. the data field of the sector is filled with the data byte specified by d. the id field for each sector is supplied by the host; that is, four data bytes per sector are needed by the fdc for c, h, r, and n (cylinder, head, sector number and sector size respectively). after formatting each sector, the host must send new values fo r c, h, r and n to the fdc for the next sector on the track. the r value (sector number) is the only value that must be changed by the host after each sector is formatted. this allows the disk to be formatted with nonsequential sect or addresses (interleaving). this incrementing and formatting continues for the whole track until the fdc enco unters a pulse on the nindex pi n again and it terminates the command. table 24 contains typical values for gap fields which are dependent upon the size of the sector and the number of sectors on each track. actual values can vary due to drive electronics.
smsc ds ? LPC47M15X page 58 rev. 08/02/2001 format fields system 34 (double density) format gap4a 80x 4e sync 12x 00 iam gap1 50x 4e sync 12x 00 idam c y l h d s e c n o c r c gap2 22x 4e sync 12x 00 data am data c r c gap3 gap 4b 3x c2 fc 3x a1 fe 3x a1 fb f8 system 3740 (single density) format gap4a 40x ff sync 6x 00 iam gap1 26x ff sync 6x 00 idam c y l h d s e c n o c r c gap2 11x ff sync 6x 00 data am data c r c gap3 gap 4b fc fe fb or f8 perpendicular format gap4a 80x 4e sync 12x 00 iam gap1 50x 4e sync 12x 00 idam c y l h d s e c n o c r c gap2 41x 4e sync 12x 00 data am data c r c gap3 gap 4b 3x c2 fc 3x a1 fe 3x a1 fb f8 table 24 ? typical values for formatting format sector size n sc gpl1 gpl2 5.25? drives fm 128 128 512 1024 2048 4096 ... 00 00 02 03 04 05 ... 12 10 08 04 02 01 07 10 18 46 c8 c8 09 19 30 87 ff ff mfm 256 256 512* 1024 2048 4096 ... 01 01 02 03 04 05 ... 12 10 09 04 02 01 0a 20 2a 80 c8 c8 0c 32 50 f0 ff ff 3.5? drives fm 128 256 512 0 1 2 0f 09 05 07 0f 1b 1b 2a 3a mfm 256 512** 1024 1 2 3 0f 09 05 0e 1b 35 36 54 74 gpl1 = suggested gpl values in read and write commands to avoid splice point between data field and id field of contiguous sections. gpl2 = suggested gpl value in format a track command. *pc/at values (typical) **ps/2 values (typical). applies with 1.0 mb and 2.0 mb drives. note: all values except sector size are in hex.
smsc ds ? LPC47M15X page 59 rev. 08/02/2001 control commands control commands differ from the other commands in that no data transfer takes place. three commands generate an interrupt when complete: read id, recalibrate, a nd seek. the other control commands do not generate an interrupt. read id the read id command is used to find the present position of the recording heads. the fdc stores the values from the first id field it is able to read into its registers. if the fdc does not find an id address mark on the diskette after the second occurrence of a pulse on the nindex pin, it then sets the ic code in status register 0 to ?01? (abnormal termination), sets the ma bit in status regi ster 1 to ?1?, and terminates the command. the following commands will generate an interrupt upon completi on. they do not return any result bytes. it is highly recommended that control commands be followed by the s ense interrupt status command. otherwise, valuable interrupt status info rmation will be lost. recalibrate this command causes the read/write head within the fdc to retract to the track 0 position. the fdc clears the contents of the pcn counter and checks the status of the ntrk0 pin fr om the fdd. as long as the ntrk0 pin is low, the dir pin remains 0 and step pulses ar e issued. when the ntrk0 pin goes high , the se bit in status register 0 is set to ?1? and the command is terminated. if the ntrk0 pin is still low after 79 step pulses have been issued, the fdc sets the se and the ec bits of status register 0 to ?1 ? and terminates the command. disks capable of handling more than 80 tracks per side may require more than one recalibrat e command to return the head back to physical track 0. the recalibrate command does not have a result phase. the sense interrupt status command must be issued after the recalibrate command to effectively terminate it and to provide verification of the he ad position (pcn). during the command phase of the recalibrate operation, the fdc is in the busy state, but during the execution phase it is in a non-busy state. at this time, another recalibrate command may be issued, and in this manner parallel recalibrate operations may be done on up to four drives at once. upon power up, the software must issue a recalibrate command to properly initialize all drives and the controller. seek the read/write head within the drive is moved from track to track under the control of the seek command. the fdc compares the pcn, which is the current head position, with the ncn and performs the following operation if there is a difference: pcn < ncn: direction signal to drive set to ?1? (step in) and issues step pulses. pcn > ncn: direction signal to drive set to ?0? (step out) and issues step pulses. the rate at which step pulses are issued is controlled by srt (stepping rate time) in the specify command. after each step pulse is issued, ncn is compared against pcn, and when ncn = pcn the se bit in status register 0 is set to ?1? and the command is terminated. during the comm and phase of the seek or re calibrate operation, the fdc is in the busy state, but dur ing the execution phase it is in the non-busy state. at this time, another seek or recalibrate command may be issued, and in this manner, para llel seek operations may be do ne on up to four drives at once. note that if implied seek is not enabled, the read and write commands should be preceded by: 1) seek command - step to the proper track 2) sense interrupt status command - terminate the seek command 3) read id - verify head is on proper track 4) issue read/w rite command. the seek command does not have a result phase. therefor e, it is highly recommended that the sense interrupt status command is issued after the seek command to te rminate it and to provide verification of the head position (pcn). the h bit (head address) in st0 will always re turn to a ?0?. when exiting powerdown mode, the fdc clears the pcn value and the status information to zero. prior to issuing the powerdown command, it is highly recommended that the user service all pending inte rrupts through the sense interrupt status command.
smsc ds ? LPC47M15X page 60 rev. 08/02/2001 sense interrupt status an interrupt signal is generated by the fdc for one of the following reasons: 1) upon entering the result phase of: a. read data command b. read a track command c. read id command d. read deleted data command e. write data command f. format a track command g. write deleted data command h. verify command 2) end of seek, relative seek, or recalibrate command the sense interrupt status command resets the interrupt sign al and, via the ic code and se bit of status register 0, identifies the cause of the interrupt. table 25 ? interrupt identification se ic interrupt due to 0 1 1 11 00 01 polling normal termination of seek or recalibrate command abnormal termination of seek or recalibrate command the seek, relative seek, and recalibrate commands have no result phase. the sense interrupt status command must be issued immediately after these commands to terminate them and to provide verification of the head position (pcn). the h (head address) bit in st0 will always return a ?0?. if a sense interrupt stat us is not issued, the drive will continue to be busy and may affect the operation of the next command. sense drive status sense drive status obtains drive status information. it has not execution phase and goes directly to the result phase from the command phase. status register 3 contains the drive status information. specify the specify command sets the initial values for each of the three internal times. the hut (head unload time) defines the time from the end of the execution phase of one of the read/write commands to the head unload state. the srt (step rate time) defines the time interval between adjacent step pulses. note that the spacing between the first and second step pulses may be shorter than the remain ing step pulses. the hlt (head load time) defines the time between when the head load signal goes high and t he read/write operation starts. the values change with the data rate speed selection and are documented in table 26. the values are the same for mfm and fm. the dma operation is selected by the nd bit. when nd is ?0?, the dma mode is selected. this part does not support non-dma mode. in dma mode, data transfers are signaled by the dma request cycles.
smsc ds ? LPC47M15X page 61 rev. 08/02/2001 configure the configure command is issued to select the special f eatures of the fdc. a c onfigure command need not be issued if the default values of t he fdc meet the system requirements. table 26 ? drive control delays (ms) hut srt 2m 1m 500k 300k 250k 2m 1m 500k 300k 250k 0 1 .. e f 64 4 .. 56 60 128 8 .. 112 120 256 16 .. 224 240 426 26.7 .. 373 400 512 32 .. 448 480 4 3.75 .. 0.5 0.25 8 7.5 .. 1 0.5 16 15 .. 2 1 26.7 25 .. 3.33 1.67 32 30 .. 4 2 hlt 2m 1m 500k 300k 250k 00 01 02 .. 7f 7f 64 0.5 1 .. 63 63.5 128 1 2 .. 126 127 256 2 4 .. 252 254 426 3.3 6.7 .. 420 423 512 4 8 . 504 508 configure default values: eis - no implied seeks efifo - fifo disabled poll - polling enabled fifothr - fifo threshold set to 1 byte pretrk - pre-compensation set to track 0 eis - enable implied seek. when set to "1", the fdc will perform a seek operation before executing a read or write command. defaults to no implied seek. efifo - a "1" disables the fifo (default). this means data tran sfers are asked for on a byte-by-byte basis. defaults to "1", fifo disabled. the threshold defaults to "1". poll - disable polling of the drives. defaults to "0", pol ling enabled. when enabled, a single interrupt is generated after a reset. no polling is performed while the drive head is loaded and the head unload delay has not expired. fifothr - the fifo threshold in the execution phase of read or write commands. this is programmable from 1 to 16 bytes. defaults to one byte. a "00" selects one byte; "0f" selects 16 bytes. pretrk - pre-compensation start track number. programmabl e from track 0 to 255. defaults to track 0. a "00" selects track 0; "ff" selects track 255. version the version command checks to see if the controller is an enha nced type or the older type (765a). a value of 90 h is returned as th e result byte.
smsc ds ? LPC47M15X page 62 rev. 08/02/2001 relative seek the command is coded the same as for seek, except for the msb of the first byte and the dir bit. dir head step direction control rcn relative cylinder number that determines ho w many tracks to step the head in or out from the current track number. dir action 0 1 step head out step head in the relative seek command differs from the seek command in that it steps the head the absolute number of tracks specified in the command instead of making a comparison aga inst an internal register. the seek command is good for drives that support a maximum of 256 tracks. relative seeks cannot be ov erlapped with other relative seeks. only one relative seek can be active at a time. relative seeks may be overlapped with seeks and recalibrates. bit 4 of status register 0 (ec) will be set if relati ve seek attempts to step outward beyond track 0. as an example, assume that a floppy drive has 300 useabl e tracks. the host needs to read track 300 and the head is on any track (0-255). if a seek command is issued, the he ad will stop at track 255. if a relative seek command is issued, the fdc will move the head the specified number of tr acks, regardless of the internal cylinder position register (but will increment the register). if the head was on track 40 (d), the maximum track that the fdc could position the head on using relative seek will be 295 (d), the initial tr ack + 255 (d). the maximum count that the head can be moved with a single relative seek command is 255 (d). the internal register, pcn, will overflow as the cylinder number crosses track 255 and will contain 39 (d). the resulting pcn value is thus (rcn + pcn) mod 256. functionally, the fdc starts counting from 0 again as the track number goes above 255 (d). it is the user?s responsibility to compensate fdc functions (precompensation track number) when accessing tracks greater than 255. the fdc d oes not keep track that it is working in an ?extended track area? (greater than 255). any command issued will use the current pcn value except for the recalibrate command, which only looks for the track0 signal. recalibrate will return an error if the head is farther than 79 due to its limitation of issuing a maximum of 80 step pulses. the user simply needs to issue a second recalibrate command. the seek command and implied seeks will function co rrectly within the 44 (d) track (299-255) area of the ?extended track area?. it is the user?s responsibility not to issue a new track position that will exceed the maximum track that is present in the extended area. to return to the standard floppy range (0-255) of tracks, a relative seek should be issued to cross the track 255 boundary. a relative seek can be used instead of the normal seek, bu t the host is required to calculate the difference between the current head location and the new (target) head location. this may require the host to issue a read id command to ensure that the head is physically on the track that softwa re assumes it to be. different fdc commands will return different cylinder results which may be difficult to k eep track of with software without the read id command. perpendicular mode the perpendicular mode command should be issued prior to executing read/write/format commands that access a disk drive with perpendicular recording capability. with this command, the length of the gap2 field and vco enable timing can be altered to accommodate the unique requirements of these drives. table 27 describes the effects of the wgate and gap bits for the perpendicular mode command. up on a reset, the fdc will default to the conventional mode (wgate = 0, gap = 0). selection of the 500 kbps and 1 mbps perpendicular modes is independent of the actual data rate selected in the data rate select register. the user must ensu re that these two data rates remain consistent. the gap2 and vco timing requirements for perpendicular reco rding type drives are dictated by the design of the read/write head. in the design of this head, a pre-erase head precedes the normal read/write head by a distance of 200 micrometers. this works out to about 38 bytes at a 1 mbps recording density. whenever the write head is enabled by the write gate signal, the pre-erase head is also activated at the same time. thus, when the write head is initially turned on, flux transitions recorded on the media fo r the first 38 bytes will not be preconditioned with the pre- erase head since it has not yet been ac tivated. to accommodate this head activation and deactivation time, the gap2 field is expanded to a length of 41 bytes. the format fields table illustrates the change in the gap2 field size for the perpendicular format. on the read back by the fdc, the controller must begin sync hronization at the beginning of the sync field. for the conventional mode, the internal pll vco is enabled (v coen) approximately 24 bytes fr om the start of the gap2 field. but, when the controller operates in the 1 mbps perpendicular mode (wgate = 1, gap = 1), vcoen goes
smsc ds ? LPC47M15X page 63 rev. 08/02/2001 active after 43 bytes to accommodate the increased gap2 field size. for both cases, and approximate two-byte cushion is maintained from the beginning of the sync field fo r the purposes of avoiding write splices in the presence of motor speed variation. for the write data case, the fdc activates write gate at the beginning of the sync field under the conventional mode. the controller then writes a new sync field, data address mark, data field, and crc. with the pre-erase head of the perpendicular drive, the write head must be activated in the gap2 field to insure a proper write of the new sync field. for the 1 mbps perpendicular mode (wgate = 1, gap = 1), 38 bytes will be written in the gap2 space. since the bit density is proportional to the data rate, 19 bytes will be written in the gap2 field for the 500 kbps perpendicular mode (wgate = 1, gap =0). it should be noted that none of the alterations in gap2 size, vco timing, or write gate timing affect normal program flow. the information provided here is just for backgro und purposes and is not needed for normal operation. once the perpendicular mode command is invoked, fdc softwa re behavior from the user standpoint is unchanged. the perpendicular mode command is enhanced to allow s pecific drives to be designated perpendicular recording drives. this enhancement allows data transfers between c onventional and perpendicular drives without having to issue perpendicular mode commands between the accesses of the different drive types, nor having to change write pre-compensation values. when both gap and wgate bits of the perpendi cular mode command are both programmed to ?0? (conventional mode), then d0, d1, d2, d3, and d4 can be progr ammed independently to ?1? for that drive to be set automatically to perpendicular mode. in this m ode the following set of conditions also apply: 1) the gap2 written to a perpendicular drive during a writ e operation will depend upon the programmed data rate. 2) the write pre-compensation given to a perpendicular mode drive will be 0ns. 3) for d0-d3 programmed to ?0? for conventional mode driv es any data written will be at the currently programmed write pre-compensation. note: bits d0-d3 can only be overwritten when ow is program med as a ?1?.if either gap or wgate is a ?1? then d0-d3 are ignored. software and hardware resets have the follow ing effect on the perpendicular mode command: 1) ?software? resets (via the dor or dsr registers) will only clear g ap and wgate bits to ?0?. d0-d3 are unaffected and retain their previous value. 2) ?hardware? resets will clear all bits (gap, wgate and d0-d3) to ?0?, i.e all conventional mode. table 27 ? effects of wgate and gap bits wgate gap mode length of gap2 format field portion of gap 2 written by write data operation 0 0 1 1 0 1 0 1 conventional perpendicular (500 kbps) reserved (conventional) perpendicular (1 mbps) 22 bytes 22 bytes 22 bytes 41 bytes 0 bytes 19 bytes 0 bytes 38 bytes lock in order to protect systems with long dma latencies agains t older application software that can disable the fifo the lock command has been added. this command should only be used by the fdc routines, and application software should refrain from using it. if an application calls for the fifo to be disabled then the configure command should be used. the lock command defines whether the efifo, fi fothr, and pretrk parameters of the configure command can be reset by the dor and dsr registers. when the lock bit is set to logic ?1? all subsequent ?software resets by the dor and dsr registers will not change the previously set parameters to their default
smsc ds ? LPC47M15X page 64 rev. 08/02/2001 values. all ?hardware? reset from the npci_reset pin wi ll set the lock bit to logic ?0? and return the efifo, fifothr, and pretrk to their default values. a status byte is returned immediately after issuing a lock command. this byte reflects the value of the lock bit set by the command byte. enhanced dumpreg the dumpreg command is designed to support system run- time diagnostics and application software development and debug. to accommodate the lock command and the enhanced perpendicular mode command the eighth byte of the dumpreg command has been modified to contain the additional data from these two commands. compatibility the LPC47M15X was designed with software compatibility in mind. it is a fully backwards- compatible solution with the older generation 765a/b disk controllers. the fdc also implements on-board registers for compatibility with the ps/2, as well as pc/at and pc/xt, floppy disk controlle r subsystems. after a hardware reset of the fdc, all registers, functions and enhancements default to a pc/at, ps/2 or ps/2 model 30 compatible operating mode, depending on how the ident and mfm bits are configured by the system bios. 6.4.5 direct support for two floppy drives the nmtr1 function is on pin 43. nmtr1 is the second alternate function on the gp22 pin. pin 43 has the io12 buffer type. the nmtr1 function is selectable as open drain or push pull as nmtr0 is through bit 6 of the fdd mode register in crf0 of ld 0. this overrides the select ion of the output type through bit 7 of t he gpio control register. it is also controlled by bit 7 of the fdd mode register. the nds1 function is on pin 41. nds1 is the second alte rnate function on the gp21 pin. pin 42 has io12 buffer type. the nds1 function is selectable as open drain or push pull as nds0 is through bit 6 of the fdd mode register in crf0 of logical device 0. this overrides the selection of the output type through bit 7 of the gpio control register. it is also controlled by bit 7 of the fdd mode register. see the runtime registers section for register information. disk change support for second floppy bit[1] in the force disk change register supports the se cond floppy. setting either of the force disk change bits active forces the internal fdd ndskchg active when the appropriate drive has been selected. the force disk change register is defined in the runtime registers section. force write protect support for second floppy bit[0] in the device disable register and fd d option register support floppy write protect. see the runtime registers section for device disable regist er description and the configur ation registers section for fdd option register description. 6.4.6 fdc swap bit the fdc_swap bit in the fdd mode register (configuration register 0xf0) can be used to swap drive 0 and drive 1. the fdc_swap is defined as follows: bit[4] fdc_swap 0 = do not swap (default) 1 = swap drive 0 (nds, nmtr pins) with drive 1 (nds, nmtr pins) 6.5 serial port (uart) the LPC47M15X incorporates two full function uarts. they are compatible with the ns16450, the 16450 ace registers and the ns16c550a. the uarts perform serial-t o-parallel conversion on received characters and parallel- to-serial conversion on transmit characters. the data rate s are independently programmable from 460.8k baud down to 50 baud. the character options are programmable for 1 star t; 1, 1.5 or 2 stop bits; even, odd, sticky or no parity; and prioritized interrupts. the uarts each contain a programm able baud rate generator that is capable of dividing the input clock or crystal by a number from 1 to 65535. the uarts are also capable of supporting the midi data rate. refer to the configuration registers for information on disabling, power down and changing the base address of the uarts. the interrupt from a uart is enabled by pr ogramming out2 of that uart to a logic ?1?. out2 being a logic ?0? disables that uart?s interrupt. the second uart also supports irda, hp-sir and ask-ir modes of operation.
smsc ds ? LPC47M15X page 65 rev. 08/02/2001 note: the uarts 1 and 2 may be configured to share an inte rrupt. refer to the configuration section for more information. register description addressing of the accessible registers of the serial port is shown below. t he base addresses of the serial ports are defined by the configuration registers (see ?configuration? section). the se rial port registers are located at sequentially increasing addresses above these base addresse s. the LPC47M15X contains two serial ports, each of which contain a register set as described below. table 28 ? addressing the serial port dlab* a2 a1 a0 register name 0 0 0 0 receive buffer (read) 0 0 0 0 transmit buffer (write) 0 0 0 1 interrupt enable (read/write) x 0 1 0 interrupt i dentification (read) x 0 1 0 fifo control (write) x 0 1 1 line control (read/write) x 1 0 0 modem control (read/write) x 1 0 1 line status (read/write) x 1 1 0 modem status (read/write) x 1 1 1 scratchpad (read/write) 1 0 0 0 divisor lsb (read/write) 1 0 0 1 divisor msb (read/write *note : dlab is bit 7 of the line control register the following section describes the operation of the registers. receive buffer register (rb) address offset = 0h, dlab = 0, read only this register holds the received incoming data byte. bit 0 is the least significant bit, which is transmitted and received first. received data is double buffered; this uses an addi tional shift register to receive the serial data stream and convert it to a parallel 8 bit word which is transferred to the receive buffer register. the shift register is not accessible. transmit buffer register (tb) address offset = 0h, dlab = 0, write only this register contains the data byte to be transmitted. the transmit buffer is double buffered, utilizing an additional shift register (not accessible) to convert the 8 bit data word to a serial format. this shift register is loaded from the transmit buffer when the transmission of the previous byte is complete. interrupt enable register (ier) address offset = 1h, dlab = 0, read/write the lower four bits of this register cont rol the enables of the five interrupt sour ces of the serial port interrupt. it is possible to totally disable the interrupt system by resetting bits 0 through 3 of this register. similarly, setting the appropriate bits of this register to a high, selected interru pts can be enabled. disabling t he interrupt system inhibits the interrupt identificati on register and disables any serial port inte rrupt out of the LPC47M15X. all other system functions operate in their normal manner, including the li ne status and modem status registers. the contents of the interrupt enable register are described below. bit 0 this bit enables the received data available interrupt (and timeout interrupts in the fifo mode) when set to logic ?1?.
smsc ds ? LPC47M15X page 66 rev. 08/02/2001 bit 1 this bit enables the transmitter holding register empty interrupt when set to logic ?1?. bit 2 this bit enables the received line status interrupt when se t to logic ?1?. the error sources causing the interrupt are overrun, parity, framing and break. the line status register must be read to determine the source. bit 3 this bit enables the modem status interrupt when set to l ogic ?1?. this is caused when one of the modem status register bits changes state. bits 4 through 7 these bits are always logic ?0?. fifo control register (fcr) address offset = 2h, dlab = x, write this is a write only register at the same location as the iir. this register is used to enable and clear the fifos, set the rcvr fifo trigger level. note: dma is not sup ported. the uart1 and uart2 fcr?s are shadowed in the uart1 fifo control shadow register (ru ntime register at offset 0x20) and uart2 fifo control shadow register (runtime register at offset 0x21). bit 0 setting this bit to a logic ?1? enables both the xmit and rcvr fifos. clearing this bit to a logic ?0? disables both the xmit and rcvr fifos and clears all bytes from both fifos. when changing from fifo mode to non-fifo (16450) mode, data is automatically cleared from the fifos. this bit must be a 1 when other bits in this register are written to or they will not be properly programmed. bit 1 setting this bit to a logic ?1? clears all bytes in the rcvr fifo and resets its counter logic to 0. the shift register is not cleared. this bit is self-clearing. bit 2 setting this bit to a logic ?1? clears all bytes in the xmit fifo and resets its counter logic to 0. the shift register is not cleared. this bit is self-clearing. bit 3 writing to this bit has no effect on the operation of the uart. the rxrdy and txrdy pins are not available on this chip. bit 4,5 reserved bit 6,7 these bits are used to set the trigger level for the rcvr fifo interrupt. interrupt identificat ion register (iir) address offset = 2h, dlab = x, read by accessing this register, the host cpu can determine the highest priority interrupt and its source. four levels of priority interrupt exist. they are in descending order of priority: 1) receiver line status (highest priority) 2) received data ready 3) transmitter holding register empty 4) modem status (lowest priority) information indicating that a prioritized interrupt is pending and the source of that interru pt is stored in the interrupt identification register (refer to interr upt control table). when the cpu accesses the iir, the serial port freezes all
smsc ds ? LPC47M15X page 67 rev. 08/02/2001 interrupts and indicates the highest priority pending interrupt to the cpu. during this cpu access, even if the serial port records new interrupts, the current indication does not change until access is complet ed. the contents of the iir are described below. bit 0 this bit can be used in either a hardwired prioritized or polled environment to indicate whether an interrupt is pending. when bit 0 is a logic ?0?, an interrupt is pending and t he contents of the iir may be used as a pointer to the appropriate internal service routine. when bit 0 is a logic ?1?, no interrupt is pending. bits 1 and 2 these two bits of the iir are used to id entify the highest priority interrupt pendi ng as indicated by the interrupt control table. bit 3 in non-fifo mode, this bit is a logic ?0?. in fifo mode th is bit is set along with bit 2 when a timeout interrupt is pending. bits 4 and 5 these bits of the iir are always logic ?0?. bits 6 and 7 these two bits are set when the fifo control register bit 0 equals 1. bit 7 bit 6 rcvr fifo trigger level (bytes) 0 0 1 0 1 4 1 0 8 1 1 14 table 29 ? interrupt control table fifo mode only interrupt identification register interrupt set and reset functions bit 3 bit 2 bit 1 bit 0 priorit y level interrupt type interrupt source interrupt reset control 0 0 0 1 - none none - 0 1 1 0 highest receiver line status overrun error, parity error, framing error or break interrupt reading the line status register 0 1 0 0 second received data available receiver data available read receiver buffer or the fifo drops below the trigger level. 1 1 0 0 second character timeout indication no characters have been removed from or input to the rcvr fifo during the last 4 char times and there is at least 1 char in it during this time reading the receiver buffer register
smsc ds ? LPC47M15X page 68 rev. 08/02/2001 fifo mode only interrupt identification register interrupt set and reset functions 0 0 1 0 third transmitter holding register empty transmitter holding register empty reading the iir register (if source of interrupt) or writing the transmitter holding register 0 0 0 0 fourth modem status clear to send or data set ready or ring indicator or data carrier detect reading the modem status register line control register (lcr) address offset = 3h, dlab = 0, read/write start lsb data 5-8 bits msb parity stop serial data this register contains the format information of the serial line. the bit definitions are: bits 0 and 1 these two bits specify the number of bits in each transmitted or received serial character. the encoding of bits 0 and 1 is as follows: the start, stop and parity bits are not included in the word length. bit 1 bit 0 word length 0 0 1 1 0 1 0 1 5 bits 6 bits 7 bits 8 bits bit 2 this bit specifies the number of stop bits in each transmitted or received serial character. the following table summarizes the information. bit 2 word length number of stop bits 0 -- 1 1 5 bits 1.5 1 6 bits 2 1 7 bits 2 1 8 bits 2 note: the receiver will ignore all stop bits beyond the first, regardless of the number used in transmitting. bit 3 parity enable bit. when bit 3 is a logic ?1?, a parity bit is generated (transmit data) or checked (receive data) between the last data word bit and the first stop bit of the serial data. (the parity bit is used to generate an even or odd number of 1s when the data word bits and the parity bit are summed).
smsc ds ? LPC47M15X page 69 rev. 08/02/2001 bit 4 even parity select bit. when bit 3 is a logic ?1? and bit 4 is a logic ?0?, an odd number of logic ?1??s is transmitted or checked in the data word bits and the parity bit. when bit 3 is a logic ?1? and bit 4 is a logic ?1? an even number of bits is transmitted and checked. bit 5 this bit is the stick parity bit. when parity is enabled it is used in conjunction with bit 4 to select mark or space parity. when lcr bits 3, 4 and 5 are 1 the parity bit is transmitted and checked as a 0 (space parity). if bits 3 and 5 are 1 and bit 4 is a 0, then the parity bi t is transmitted and checked as 1 (mark parity). if bit 5 is 0 stick parity is disabled. bit 6 set break control bit. when bit 6 is a logic ?1?, the trans mit data output (txd) is forced to the spacing or logic ?0? state and remains there (until reset by a low level bit 6) rega rdless of other transmitter activity. this feature enables the serial port to alert a termi nal in a communications system. bit 7 divisor latch access bit (dlab). it must be set high (logic ?1?) to access the divisor latches of the baud rate generator during read or write operations. it must be set low (logic ?0?) to access the receiver buffer register, the transmitter holding register, or the interrupt enable register. modem control register (mcr) address offset = 4h, dlab = x, read/write this 8 bit register controls the interface with the mode m or data set (or device emulating a modem). the contents of the modem control register are described below. bit 0 this bit controls the data terminal ready (ndtr) output. w hen bit 0 is set to a logic ?1?, the ndtr output is forced to a logic ?0?. when bit 0 is a logic ?0?, the ndtr output is forced to a logic ?1?. bit 1 this bit controls the request to send (nrts) output. bit 1 affects the nrts output in a manner identical to that described above for bit 0. bit 2 this bit controls the output 1 (out1) bit. this bit does not have an output pin and can only be read or written by the cpu. bit 3 output 2 (out2). this bit is used to enable an uart interrupt. when out2 is a logic "0", the serial port interrupt output is forced to a high impedance state - disabled. when out2 is a logic "1", the serial port interrupt outputs are enabled. bit 4 this bit provides the loopback feature fo r diagnostic testing of the serial port. when bit 4 is set to logic ?1?, the following occur: 1) the txd is set to the marking state(logic ?1?). 2) the receiver serial input (rxd) is disconnected. 3) the output of the transmitter shift register is ?l ooped back? into the receiver shift register input. 4) all modem control inputs (ncts, ndsr, nri and ndcd) are disconnected. 5) the four modem control outputs (ndtr, nrts, out1 and out2) are internally connected to the four modem control inputs (ndsr, ncts, ri, dcd). 6) the modem control output pins are forced inactive high. 7) data that is transmitted is immediately received. this feature allows the processor to verify the transmit and receive data paths of the serial port. in the diagnostic mode, the receiver and the transmitter interrupts are fu lly operational. the modem c ontrol interrupts are also
smsc ds ? LPC47M15X page 70 rev. 08/02/2001 operational but the interrupts? sources are now the lower f our bits of the modem cont rol register instead of the modem control inputs. the interrupts are still c ontrolled by the interrupt enable register. bits 5 through 7 these bits are permanently set to logic zero. line status register (lsr) address offset = 5h, dlab = x, read/write bit 0 data ready (dr). it is set to a logic ?1? whenever a complete incoming character has been received and transferred into the receiver buffer register or the fifo. bit 0 is re set to a logic ?0? by reading all of the data in the receive buffer register or the fifo. bit 1 overrun error (oe). bit 1 indicates that data in the rece iver buffer register was not read before the next character was transferred into the register, thereb y destroying the previous character. in fifo mode, an overrun error will occur only when the fifo is full and the next character has been completely received in the shift register, the character in the shift register is overwritten but not trans ferred to the fifo. the oe indicator is set to a logic ?1? immediately upon detection of an overrun condition, and re set whenever the line status register is read. bit 2 parity error (pe). bit 2 indicates that the received data character does not have the co rrect even or odd parity, as selected by the even parity select bit. the pe is set to a logic ?1? upon detection of a parity error and is reset to a logic ?0? whenever the line status register is read. in the fifo mode this e rror is associated with the particular character in the fifo it applies to. this error is indicat ed when the associated character is at the top of the fifo. bit 3 framing error (fe). bit 3 indicates that the received character did not have a valid stop bit. bit 3 is set to a logic ?1? whenever the stop bit following the last data bit or parity bit is detected as a zero bit (spacing level). the fe is reset to a logic ?0? whenever the line status re gister is read. in the fi fo mode this error is associated with the particular character in the fifo it applies to. this error is indicate d when the associated character is at the top of the fifo. the serial port will try to resynchronize after a framing erro r. to do this, it assumes that the framing error was due to the next start bit, so it samples this ?sta rt? bit twice and then takes in the ?data?. bit 4 break interrupt (bi). bit 4 is set to a logic ?1? whenever th e received data input is held in the spacing state (logic ?0?) for longer than a full word transmission time (that is, the total time of the start bit + data bits + parity bits + stop bits). the bi is reset after the cpu reads the contents of the li ne status register. in the fifo mode this error is associated with the particular character in the fifo it appli es to. this error is indicated when the associated character is at the top of the fifo. when break occurs only one zero character is loaded into the fifo. restarting after a break is received, requires the serial data (rxd ) to be logic ?1? for at least ? bit time. note: bits 1 through 4 are the error conditions that produc e a receiver line status inte rrupt whenever any of the corresponding conditions are detect ed and the interrupt is enabled. bit 5 transmitter holding register empty (thre). bit 5 indicates t hat the serial port is ready to accept a new character for transmission. in addition, this bit causes the serial port to issue an interrupt when the transmitter holding register interrupt enable is set high. the thre bit is set to a logic ?1? when a character is transferred from the transmitter holding register into the transmitter shift regist er. the bit is reset to logic ?0? whenever the cpu loads the transmitter holding register. in the fifo mode this bit is set when the xmit fifo is empty, it is cleared when at least 1 byte is written to the xmit fifo. bit 5 is a read only bit. bit 6 transmitter empty (temt). bit 6 is set to a logic ?1? whenever the transmitter holding register (thr) and transmitter shift register (tsr) are both empty. it is reset to logic ?0? whenever either the thr or tsr contains a data character. bit 6 is a read only bit. in the fifo mode this bit is set whenever the thr and tsr are both empty,
smsc ds ? LPC47M15X page 71 rev. 08/02/2001 bit 7 this bit is permanently set to logic ?0? in the 450 mode. in the fifo mode, this bit is set to a logic ?1? when there is at least one parity error, framing error or break indication in the fifo. this bit is cleared when the lsr is read if there are no subsequent errors in the fifo. modem status register (msr) address offset = 6h, dlab = x, read/write this 8 bit register provides the current state of the control lines from the modem (or peripheral device). in addition to this current state information, four bits of the modem status register (msr) provide change information. these bits are set to logic ?1? whenever a control input from the mode m changes state. they are reset to logic ?0? whenever the modem status register is read. bit 0 delta clear to send (dcts). bit 0 indicates that the ncts i nput to the chip has changed state since the last time the msr was read. bit 1 delta data set ready (ddsr). bit 1 indicates that the nd sr input has changed state si nce the last time the msr was read. bit 2 trailing edge of ring indicator (teri). bit 2 indicates that the nri input has changed from logic ?0? to logic ?1?. bit 3 delta data carrier detect (ddcd). bit 3 indicates that the ndcd inpu t to the chip has changed state. note: whenever bit 0, 1, 2, or 3 is set to a logi c ?1?, a modem status interrupt is generated. bit 4 this bit is the complement of the clear to send (ncts) input. if bit 4 of the mcr is set to logic ?1?, this bit is equivalent to nrts in the mcr. bit 5 this bit is the complement of the data set ready (ndsr) i nput. if bit 4 of the mcr is set to logic ?1?, this bit is equivalent to dtr in the mcr. bit 6 this bit is the complement of the ring indicator (nri) input. if bit 4 of the mcr is set to logic ?1?, this bit is equivalent to out1 in the mcr. bit 7 this bit is the complement of the data carrier detect (ndcd) input. if bit 4 of the mcr is se t to logic ?1?, this bit is equivalent to out2 in the mcr. scratchpad register (scr) address offset =7h, dlab =x, read/write this 8 bit read/write register has no effect on the operation of the serial port. it is intended as a scratchpad register to be used by the programmer to hold data temporarily. programmable baud rate generator (and divisor latches dlh, dll) the serial port contains a programmable baud rate generato r that is capable of dividing the internal pll clock by any divisor from 1 to 65535. the internal pll clock is divided down to generate a 1.8462mhz frequency for baud rates less than 38.4k, a 1.8432mhz frequency for 115. 2k, a 3.6864mhz frequency for 230.4k and a 7.3728mhz frequency for 460.8k. this output frequen cy of the baud rate generator is 16 x the baud rate. two 8 bit latches
smsc ds ? LPC47M15X page 72 rev. 08/02/2001 store the divisor in 16 bit binary format. these divisor latc hes must be loaded during initialization in order to insure desired operation of the baud rate generator. upon loadi ng either of the divisor latc hes, a 16 bit baud counter is immediately loaded. this prevents long counts on initial load. if a 0 is loa ded into the brg registers the output divides the clock by the number 3. if a 1 is loaded the output is the inverse of the input oscillator. if a two is loaded the output is a divide by 2 signal with a 50% duty cycle. if a 3 or greater is loaded the output is low for 2 bits and high for the remainder of the count. the input clock to the brg is a 1.8462 mhz clock. table 30 shows the baud rates possible. effect of the reset on register file the reset function (details the effect of the reset input on each of the regist ers of the serial port. fifo interrupt mode operation when the rcvr fifo and receiver interrupts are enabled (fcr bit 0 = ?1?, ier bit 0 = ?1?), rcvr interrupts occur as follows: a. the receive data available interrupt will be iss ued when the fifo has reached its programmed trigger level; it is cleared as soon as the fifo drops below its programmed trigger level. b. the iir receive data available indication also occurs when the fifo trigger level is reached. it is cleared when the fifo drops below the trigger level. c. the receiver line status interrupt (iir=06h), has higher priority than the received data available (iir=04h) interrupt. d. the data ready bit (lsr bit 0) is set as soon as a character is transferred from the shift register to the rcvr fifo. it is reset when the fifo is empty. when rcvr fifo and receiver interrupts are enabled, rcvr fifo timeout interrupts occur as follows: a. a fifo timeout interrupt occurs if all the following conditions exist: at least one character is in the fifo. the most recent serial character re ceived was longer than 4 continuous character times ago. (if 2 stop bits are programmed, the second one is included in this time delay). the most recent cpu read of the fifo was l onger than 4 continuous character times ago. this will cause a maximum character received to interr upt issued delay of 160 msec at 300 baud with a 12 bit character. b. character times are calculated by using the rclk input for a clock signal (this makes the delay proportional to the baudrate). c. when a timeout interrupt has occurred it is cleared and the timer reset when the cpu reads one character from the rcvr fifo. d. when a timeout interrupt has not occurred the timeout timer is reset after a new character is received or after the cpu reads the rcvr fifo. when the xmit fifo and transmitter interrupts are enabled (f cr bit 0 = ?1?, ier bit 1 = ?1?), xmit interrupts occur as follows: a. the transmitter holding register interrupt (02h) occurs when the xmit fifo is empty; it is cleared as soon as the transmitter holding register is written to (1 of 16 characters may be written to the xmit fifo while servicing this interrupt) or the iir is read. b. the transmitter fifo empty indications will be delayed 1 character time minus the last stop bit time whenever the following occurs: thre=1 and there have not been at least two bytes at the same time in the transmitter fifo since the last thre=1. the tr ansmitter interrupt after changing fcr0 will be immediate, if it is enabled. character timeout and rcvr fifo trigger level interrupts have the same priority as the current received data available interrupt; xmit fifo empty has the same priority as the current transmitter holding register empty interrupt.
smsc ds ? LPC47M15X page 73 rev. 08/02/2001 fifo polled mode operation with fcr bit 0 = ?1? resetting ier bits 0, 1, 2 or 3 or all to zero puts the uart in the fifo polled mode of operation. since the rcvr and xmitter are controlled separately, either one or both can be in the polled mode of operation. in this mode, the user?s program wi ll check rcvr and xmitter status via t he lsr. lsr definitions for the fifo polled mode are as follows: bit 0=1 as long as there is one byte in the rcvr fifo. bits 1 to 4 specify which error(s) have occurred. characte r error status is handled the same way as when in the interrupt mode, the iir is not affected since eir bit 2=0. bit 5 indicates when the xmit fifo is empty. bit 6 indicates that both the xmit fifo and shift register are empty. bit 7 indicates whether there are any errors in the rcvr fifo. there is no trigger level reached or timeout condition indi cated in the fifo polled mode, however, the rcvr and xmit fifos are still fully capa ble of holding characters. table 30 ? baud rates desired baud rate divisor used to generate 16x clock percent error difference between desired and actual 1 high speed bit 2 50 2304 0.001 x 75 1536 - x 110 1047 - x 134.5 857 0.004 x 150 768 - x 300 384 - x 600 192 - x 1200 96 - x 1800 64 - x 2000 58 0.005 x 2400 48 - x 3600 32 - x 4800 24 - x 7200 16 - x 9600 12 - x 19200 6 - x 38400 3 0.030 x 57600 2 0.16 x 115200 1 0.16 x 230400 32770 0.16 1 460800 32769 0.16 1 note 1 : the percentage error for all baud rates, except where indicated otherwise, is 0.2%. note 2 : the high speed bit is located in the device configuration space.
smsc ds ? LPC47M15X page 74 rev. 08/02/2001 table 31 ? reset function table register/signal reset control reset state interrupt enable register reset all bits low interrupt identification reg. reset bit 0 is high; bits 1 - 7 low fifo control reset all bits low line control reg. reset all bits low modem control reg. reset all bits low line status reg. reset all bits low except 5, 6 high modem status reg. reset bits 0 - 3 low; bits 4 - 7 input txd1, txd2 reset high intrpt (rcvr errs) reset/read lsr low intrpt (rcvr data ready) reset/read rbr low intrpt (thre) reset/readiir/write thr low out2b reset high rtsb reset high dtrb reset high out1b reset high rcvr fifo reset/ fcr1*fcr0/_fcr0 all bits low xmit fifo reset/ fcr1*fcr0/_fcr0 all bits low table 32 ? register summary for an individual uart channel register address* register name register symbol bit 0 bit 1 addr = 0 dlab = 0 receive buffer register (read only) rbr data bit 0 (note 1) data bit 1 addr = 0 dlab = 0 transmitter holding register (write only) thr data bit 0 data bit 1 addr = 1 dlab = 0 interrupt enable register ier enable received data available interrupt (erdai) enable transmitter holding register empty interrupt (ethrei) addr = 2 interrupt ident. regist er (read only) iir ?0? if interrupt pending interrupt id bit addr = 2 fifo control register (write only) fcr (note 7) fifo enable rcvr fifo reset addr = 3 line control register lcr word length select bit 0 (wls0) word length select bit 1 (wls1) addr = 4 modem control register mcr data terminal ready (dtr) request to send (rts) addr = 5 line status register lsr data ready (dr) overrun error (oe) addr = 6 modem status register msr delta clear to send (dcts) delta data set ready (ddsr)
smsc ds ? LPC47M15X page 75 rev. 08/02/2001 register address* register name register symbol bit 0 bit 1 addr = 7 scratch register (note 4) scr bit 0 bit 1 addr = 0 dlab = 1 divisor latch (ls) ddl bit 0 bit 1 addr = 1 dlab = 1 divisor latch (ms) dlm bit 8 bit 9 *dlab is bit 7 of the line control register (addr = 3). note 1: bit 0 is the least significant bit. it is the first bit serially transmitted or received. note 2: when operating in the xt mode, this bit will be set an y time that the transmitter shift register is empty. table 32 ? register summary for an individual uart channel (continued) bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 data bit 2 data bit 3 data bit 4 data bit 5 data bit 6 data bit 7 data bit 2 data bit 3 data bit 4 data bit 5 data bit 6 data bit 7 enable receiver line status interrupt (elsi) enable modem status interrupt (emsi) 0 0 0 0 interrupt id bit interrupt id bit (note 5) 0 0 fifos enabled (note 5) fifos enabled (note 5) xmit fifo reset dma mode select (note 6) reserved reserved rcvr trigger lsb rcvr trigger msb number of stop bits (stb) parity enable (pen) even parity select (eps) stick parity set break divisor latch access bit (dlab) out1 (note 3) out2 (note 3) loop 0 0 0 parity error (pe) framing error (fe) break interrupt (bi) transmitter holding register (thre) transmitter empty (temt) (note 2) error in rcvr fifo (note 5) trailing edge ring indicator (teri) delta data carrier detect (ddcd) clear to send (cts) data set ready (dsr) ring indicator (ri) data carrier detect (dcd) bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 bit 2 bit 3 bit 4 bit 5 bit 6 bit 7 bit 10 bit 11 bit 12 bit 13 bit 14 bit 15 note 3: this bit no longer has a pin associated with it. note 4: when operating in the xt mode, this register is not available. note 5: these bits are always zero in the non-fifo mode. note 6: writing a one to this bit has no effect. dma modes are not supported in this chip. note 7: the uart1 and uart2 fcr?s are shadowed in the uart 1 fifo control shadow re gister (runtime register at offset 0x20) and uart2 fifo control shadow re gister (runtime register at offset 0x21).
smsc ds ? LPC47M15X page 76 rev. 08/02/2001 notes on serial port operation txd2 pin the inactive state of the txd2 (pin 96) can be selected through the txd2_mode bit, bit 5 of the serial port 2 mode configuration register (at 0xf0 in ld5). fifo mode operation: general the rcvr fifo will hold up to 16 bytes regardless of which trigger level is selected. tx and rx fifo operation the tx portion of the uart transmits data through txd as soon as the cpu loads a byte into the tx fifo. the uart will prevent loads to the tx fifo if it currently holds 16 characters . loading to the tx fifo will again be enabled as soon as the next character is transferred to the tx shift register. these capabilities account for the largely autonomous operation of the tx. the uart starts the above oper ations typically with a tx interrupt. the chip issues a tx interrupt whenever the tx fifo is empty and the tx interrupt is en abled, except in the following instance. assume that the tx fifo is empty and the cpu starts to load it. when the first byte enters t he fifo the tx fifo empty interrupt will transition from active to inactive. depending on the execution speed of the service routine software, the uart may be able to transfer this byte from the fifo to the shift register before the cpu loads another byte. if this happens, the tx fifo will be empty again and typically the uart?s interrupt line wo uld transition to the active state. this could cause a system with an interrupt control unit to record a tx fifo empty condition, even though the cpu is currently servicing that interrupt. therefore, after the first byte has been loaded into the fifo the uart will wait one serial character transmission time before issuing a new tx fifo empty interrupt. this one character tx interrupt delay will remain active until at least two bytes have th e tx fifo empties after th is condition, the tx been loaded into the fifo, concurrently. when interrupt will be activated without a one character delay . rx support functions and operation are quite different from t hose described for the transmitter. the rx fifo receives data until the number of bytes in the fifo equals the selected interrupt trigger level. at that time if rx interrupts are enabled, the uart will issue an interrupt to the cpu. the rx fifo will continue to stor e bytes until it holds 16 of them. it will not accept any more data when it is full. any more data entering the rx shift register will set the overrun error flag. normally, the fifo depth and the programmable tr igger levels will give the cpu ample time to empty the rx fifo before an overrun occurs. one side-effect of having a rx fifo is that the selected interrupt trigger level may be above the data level in the fifo. this could occur when data at t he end of the block contains fewer bytes than the trigger level. no interrupt would be issued to the cpu and the data would remain in the uart. to prevent the software from having to check for this situation the chip incorporates a timeout interrupt . the timeout interrupt is activated when there is a least one byte in the rx fifo, and neither the cpu nor the rx shift register has accessed the rx fifo within 4 character times of the last byte. the timeout interrupt is cleared or reset when the cpu reads the rx fifo or another character enters it. these fifo related features allow optimization of cpu/uart transactions and are especiall y useful given the higher baud rate capability (256 kbaud). 6.6 infrared interface the infrared interface provides a two-way wireless comm unications port using infrared as a transmission medium. two ir implementations have been provided for the second ua rt in this chip (logical device 5), irda and amplitude shift keyed ir. the ir transmission can use the standard uart2 txd2 and rxd2 pins or optional irtx2 and irrx2 pins. these can be selected th rough the configuration registers. irda 1.0 allows serial communication at baud rates up to 115.2 kbps. each word is sent serially beginning with a zero value start bit. a zero is signaled by sending a single ir pulse at the beginning of the serial bit time. a one is signaled by sending no ir pulse during the bit time. please refer to the ac timi ng for the parameters of these pulses and the irda waveform.
smsc ds ? LPC47M15X page 77 rev. 08/02/2001 the amplitude shift keyed ir allows asynchronous seri al communication at baud rates up to 19.2k baud. each word is sent serially beginning with a zero value start bit. a zero is signaled by sending a 500khz waveform for the duration of the serial bit time. a one is signaled by se nding no transmission during the bit time. please refer to the ac timing for the parameters of the ask-ir waveform. if the half duplex option is ch osen, there is a time-out when the direction of the transmiss ion is changed. this time- out starts at the last bit transferred during a transmission a nd blocks the receiver input unt il the timeout expires. if the transmit buffer is loaded with more data before the time-out expires, the timer is restarted after the new byte is transmitted. if data is loaded into the transmit buffer while a character is being received, the transmission will not start until the time-out expires after the last receive bit has been received. if the start bit of another character is received during this time-out, the timer is restarted after the new character is received. the ir half duplex time-out is programmable via crf2 in logical device 5. this register allows the time-out to be programmed to any value between 0 and 10msec in 100usec increments. the following figure shows the block diagram of the ir components in the LPC47M15X: ace uart irda sir sharp ask com ace registers output mux ir com host interface ir options register, bit 6 ir transmit pins the following description pertains to the txd2/irtx and irtx2 pins of the LPC47M15X. following a vtr por, the irtx and irtx2 pins will be out put and low. they will remain low until one of the following conditions are met: irtx2/gp35 pin. this pin defaults to the irtx2 function. 1) this pin will remain low following a vcc por until irtx2 function is selected for the pin, serial port 2 is enabled by setting the activa te bit, at which time the pin will reflect the stat e of the transmit output of the ir block (if ir is enabled through the ir option register fo r serial port 2). 2) this pin will remain low following a vcc por until the gpio output function is selected for the pin, at which time the pin will reflect the state of the gpio data bit if it is configured as an output. gp53/txd2(irtx) pin. this pin de faults to the gpio output function. 1) this pin will remain low following a vcc por until the txd2 (irtx) function is selected for the pin and serial port 2 is enabled by setting the activate bit, at which time the pin will reflect the state of the ir transmit output of the ir block (if ir is enabled through the ir option register for serial port 2). 2) this pin will remain low following a vcc por until the txd2 function is selected for the pin and serial port 2 is enabled by setting the activate bit, at which time the pin will reflect the state of the transmit output of serial port 2. following a vcc por, setting the txd2_mode bit (bit 5 in serial port 2 mode register, 0xf0 in logical device 5 configuration registers) to ?1? will change the st ate of the txd2 pin from low to tristate, regardless of the function selected on the pin (gpio of txd2), regardless of the state of t he activate bit for serial port 2 and regardless of the state of vc c. when vcc is removed from the part whil e the txd2_mode bit is set to ?1?, the txd2 pin will remain tristate unless a vtr por occurs, which will reset the txd2_mode bit. 3) this pin will remain low following a vcc por until the corresponding gpio data bit (gp5 register bit 3) is set or the polarity bit in the gp53 control register is set. when serial port 2 is subsequently deactiva ted, the txd2/irtx pin will be drive low. the txd2_mode bit is implemented for modems that do not a ssert the ring indicator pin when txd2 is sensed low. if required, this bit should be used as follows:
smsc ds ? LPC47M15X page 78 rev. 08/02/2001 ? when the activate bit for serial port 2 is cleared pr ior to entering a sleep state, set the txd2_mode bit. ? when the activate bit for serial port 2 is set, upon exiting a sleep state clear the txd2_mode bit. the irtx2 pin is not affected by the txd2_mode bit. 6.7 mpu-401 midi uart 6.7.1 overview serial port 3 is used exclusively in the LPC47M15X as an mpu-401-compatible midi interface. the LPC47M15X mpu-401 hardware includes a host interface, an mpu-401 command controller, confi guration registers, and a compatible uart (figure 2). each of these components are discussed in detail, below. only the mpu-401 uart (pass-through) mode is inclu ded in this implementation. mpu-401 uart mode is supported on the sound blaster 16 seri es-compatible midi hardware. the sound blaster 16 hardware is supported by microsoft windows operating systems. in mpu-401 uart mode, data is transferred without modifi cation between the host and the midi device (uart). once uart mode is entered using the uart mode command (3fh), the only mpu-401 command that the interface recognizes is reset (ffh). host interface irq sa[15:0] sd[7:0] uart midi_in midi_out mpu-401 command controller tx rx nio r niow configuration registers figure 2 ? mpu-401 midi interface note: this figure is for illustration purposes only and is not intended to suggest specific implementation details. 6.7.2 host interface overview the host interface includes two contiguous 8-bit run-time registers (the status/command port and the data port), and an interrupt. for illustration purposes, the host interfac e block shown in figure 2 uses standard isa signaling. address decoding and interrupt selection for the host interf ace are determined by device configuration registers (see section ?mpu-401configuration registers?). i/o addresses the sound blaster 16 mpu-401 uart m ode midi interface requires two consecutive i/o addresses with possible base i/o addresses of 300h and 330h. the default is 330h. the LPC47M15X mp u-401 i/o base address is programmable on even-byte boundaries th roughout the entire i/o addr ess range (see section ?activate and i/o base address?). registers (ports) the run-time registers in the mpu-401 host interface are shown below in table 33.
smsc ds ? LPC47M15X page 79 rev. 08/02/2001 table 33 ? mpu-401 host interface registers register name address type description midi data mpu-401 i/o base address r/w used for midi transmit data, midi receive data, and mpu-401 command acknowledge. status mpu-401 i/o base address + 1 r used to indicate the send/receive status of the midi data port. command mpu-401 i/o base address + 1 w used for mpu-401 commands. 6.7.3 midi data port the midi data port exchanges midi transmit and midi receive data between the mpu-401 uart interface and the host. the midi data port is read/write (table 34). the midi data port is also used to return the command acknowledge byte ?feh? following host writes to the command port. the midi data port is full-duplex; i.e., the trans mit and receive buffers can be used simultaneously. an interrupt is generated when either midi receive data or a command acknowledge is available to the host in the midi data register. see section ?bit 7 ? midi receive buffer empty? and ?interrupt? table 34 ? midi data port mpu-401 i/o base address d7 d6 d5 d4 d3 d2 d1 d0 default type r/w r/w r/w r/w r/w r/w r/w r/w n/a name midi data/command-acknowledge register 6.7.4 6.7.5 status port the status port is used to indicate the state of the transmit and receive buffers in the midi data port. the status port is read-only (table 35). status port bit 6 is midi transmit busy, bit 7 is midi receive buffer empty. the remaining bits in the status port are reserved. table 35 ? mpu-401 status port mpu-401 i/o base address+1 d7 d6 d5 d4 d3 d2 d1 d0 default type r r r r r r r r 0x80 bit name midi rx buffer empty midi tx busy 0 0 0 0 0 0 bit 7 ? midi receive buffer empty bit 7 midi receive buffer empty indicates the read state of the midi data port (table 36). if the mrbe bit is ?0?, midi read/command acknowledge data is available to the host. if the mrbe bit is ?1?, midi read/command acknowledge data is not available to the host. the mpu-401 interrupt output is active ?1? when the midi receive buffer empty bit is ?0?. the mpu-401 interrupt output is inactive ?0? when the midi receive buffer empty bi t is ?1?. see section ?int errupt? for more information. table 36 ? midi receive buffer empty status bit status port description d7 0 midi read/command acknowledge data is available to the host. 1 midi read/command acknowledge data is not available to the host. bit 6 ? midi transmit busy bit 6 midi transmit busy indicates the send (write) st ate of the midi data port and command port (table 37)
smsc ds ? LPC47M15X page 80 rev. 08/02/2001 there are no interrupts associated wi th midi transmit (write) data. table 37 ? midi transmit busy status bit status port description d6 0 the mpu-401 interface is ready to accept a data/command byte from the host. 1 the mpu-401 interface is not ready to accept a data/command byte from the host. bits[5:0] reserved (reserved bits cannot be wr itten and return ?0? when read). command port the command port is used to transfer mpu-401 commands to the command controller. the command port is write- only (table 38). see section ?mpu-401 command controller? below. table 38 ? mpu-401 command port mpu-401 i/o base address+1 d7 d6 d5 d4 d3 d2 d1 d0 default type w w w w w w w w n/a name command register interrupt the mpu-401 irq is asserted (?1?) when either midi receiv e data or a command acknowledge byte is available tot he host in the midi data register (figure 3). the irq is deasserted (?0?) when the host reads the midi data port. note: if, following a host read, data is still ava ilable in the 16c550a receive fifo, t he irq will remain asserted (?1?). the irq is enabled when the ?activate? bit in the mpu-401 c onfiguration registers logical device block is asserted ?1?. if the activate bit is deasserted ?0?, the mpu-401 ir q cannot be asserted (see se ction ?mpu-401 configuration registers?). the mpu-401 irq is not affected by midi write data, 16c55 0a transmit-related functions or receiver line status interrupts. the factory default sound blaster 16 mpu-401 irq is 5. midi rx clock 4 midi rx data byte n midi rx data byte n+1 midi_in data ready 1 irq 3 nread 2 n ote: irq remains asserted until read fifo is empty figure 3 ? mpu-401 interrupt note 1: data ready represents the data ready bit b0 in the 16c550a uart line status register. note 2: nread represents host read operations from the midi data register. note 3: irq is the mpu-401 host interface irq shown in figure 2. the 16c550a uart receive fifo threshold=1. note 4: midi rx clock is the midi bit clock. the midi bit clock period is 32us.
smsc ds ? LPC47M15X page 81 rev. 08/02/2001 6.7.6 mpu-401 command controller overview commands are written by the host to the mpu-401 midi in terface through the command register (table 33) and are immediately interpreted by the mpu-401 command co ntroller shown in figure 2. the mpu-401 command controller in this implementation only responds to the mpu-401 reset (ffh) and uart mode (3fh) commands. all other commands are ignored. under certain conditions, the command controller acknowledges mpu-401 commands with a command acknowledge byte (feh). reset command the reset command is ffh. the reset command resets t he mpu-401 midi interface. reset disables the mpu- 401 uart mode command, disables the 16c550a uart, clears the receive fifo. the command controller places the command acknowledge byte ?feh? in the midi data por t read buffer if the interface is not in the uart mode. the reset command is executed but not acknowledged when t he command is received while the interface is in the uart mode. when the mpu-401 is reset, receive data from the midi_in port as well as data written by the host to the midi data port is ignored. the mpu-401 midi interface is reset fo llowing the reset command or por. uart mode command the uart mode command is 3fh. the uart mode co mmand clears the 16c550a transmit and receive fifos, places the command acknowledge byte (feh) in the midi data port receive buffer, and enables the 16c550a uart for transmit and receive operations. in uart mode, the mpu-401 interface passes midi read and write data directly between the host (using the midi data port) and the 16c550a uart transmit and receive buffers. the mpu-401 command controller ignores the uart mode command when the mpu-401 interface is already in uart mode. the mpu-401 reset command is executed but not acknow ledged by the mpu-401 command controller in uart mode (see section ?reset command?, above). command acknowledge byte under certain conditions, the command controller ackn owledges the reset and uart mode commands with a command acknowledge byte (feh). the command acknowledge byte appears as read-data in the midi data port. note: the command acknowledge byte will appear as the next av ailable data byte in the re ceive buffer of the midi data port. for example if the receive fifo is not empty when an mpu-401 reset command is received, the command acknowledge will appear first, before any unread fifo data. in the examples above, the receive fifo is cleared before the command acknowledge byte is placed in the midi data port read buffer. 6.7.7 midi uart overview the uart is used to transmit and receive midi protocol data from the midi data port in the host interface (see section ?host interface?). the midi protocol requires 31.25k baud ( 1%) and 10 bits total per frame: 1 start bit, 8 data bits, no parity, and 1 stop bit. for example, there are 320 microseconds per seri al midi data byte. midi data is transferred lsb first (figure 7). the uart is configured in full-duplex mode for the mpu- 401 midi interface, with 16-byte send/receive fifos.
smsc ds ? LPC47M15X page 82 rev. 08/02/2001 midi rx clock 1 midi rx data byte (01h) midi_in figure 4 ? midi data byte example note 1 : midi rx clock is the midi bit clock. the midi bit clock period is 32us. 6.7.8 mpu-401 configuration registers the LPC47M15X configuration r egisters are in logical device b (see ?conf iguration? section). the configuration registers contain the mpu-401 activate, base address and interrupt select. the defaults for the base address and interrupt select configuration register s match the mpu-401 factory defaults. activate and i/o base address when the activate bit d0 is ?0?, t he mpu-401 i/o base address dec oder is disabled, the irq is always deasserted, and the mpu-401 hardware is in a mini mum power-consumption state. when the activate bit is ?1?, the mpu-401 i/o base address decoder and the irq are enabled, and the mpu-401 hardware is fully powered. register 0x60 is the mpu-401 i/o base address high by te, register 0x61 is the mpu-401 i/o base address low byte. the mpu-401 i/o base address is programma ble on even-byte bou ndaries. the va lid mpu-401 i/o base address range is 0x0100 ? 0x0ffe. see section ?host interface?. 6.8 parallel port the LPC47M15X incorporates an ibm xt/at compatible para llel port. this supports the optional ps/2 type bi- directional parallel port (spp), the enhanced parallel port (epp) and the extended capabilities port (ecp) parallel port modes. refer to the configuration registers for in formation on disabling, power down, changing the base address of the parallel port, and sele cting the mode of operation. the parallel port also incorporates smsc?s chiprotect circ uitry, which prevents possible damage to the parallel port due to printer power-up. the functionality of the parallel port is achieved through the use of eight addressable ports, with their associated registers and control gating. the contro l and data port are read/write by the cpu, the status port is read/write in the epp mode. the address map of the parallel port is shown below: data port base address + 00h status port base address + 01h control port base address + 02h epp addr port base address + 03h epp data port 0 base address + 04h epp data port 1 base address + 05h epp data port 2 base address + 06h epp data port 3 base address + 07h the bit map of these registers is: d0 d1 d2 d3 d4 d5 d6 d7 note data port pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 1 status port tmout 0 0 nerr slct pe nack nbusy 1 control port strobe autofd ninit slc irqe pcd 0 0 1 epp addr port pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 2 epp data port 0 pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 2
smsc ds ? LPC47M15X page 83 rev. 08/02/2001 d0 d1 d2 d3 d4 d5 d6 d7 note epp data port 1 pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 2 epp data port 2 pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 2 epp data port 3 pd0 pd1 pd2 pd3 pd4 pd5 pd6 pd7 2 note 1: these registers are available in all modes. note 2: these registers are only available in epp mode. table 39 ? parallel port connector host connector pin number standard epp ecp 1 83 nstrobe nwrite nstrobe 2-9 68-75 pd<0:7> pdat a<0:7> pdata<0:7> 10 80 nack intr nack 11 79 busy nwait busy, periphack(3) 12 78 pe (user defined) perror, nackreverse (3) 13 77 slct (user defined) select 14 82 nalf ndatastb nautofd, hostack(3) 15 81 nerror (user defined) nfault (1) nperiphrequest (3) 16 66 ninit nreset ninit(1) nreverserqst(3) 17 67 nslctin naddrstrb nselectin(1,3) (1) = compatible mode (3) = high speed mode note: for the cable interconnection required for ecp suppor t and the slave connector pin numbers, refer to the ieee 1284 extended capabilities port prot ocol and isa standard, rev. 1.14, july 14, 1993. this document is available from microsoft. 6.8.1 ibm xt/at compatible, bi-directional and epp modes data port address offset = 00h the data port is located at an offset of ?00h? from the base address. the data register is cleared at initialization by reset. during a write operation, the data register latches the contents of the intern al data bus. the contents of this register are buffered (non inverting) and output ont o the pd0 - pd7 ports. during a read operation in spp mode, pd0 - pd7 ports are buffered (not latched) and output to the host cpu. status port address offset = 01h the status port is located at an offset of ?01h? from the base address. the c ontents of this register are latched for the duration of a read cycle. the bits of the status po rt are defined as follows: bit 0 tmout - time out this bit is valid in epp mode only an d indicates that a 10 usec time out has occurred on the epp bus. a logic o means that no time out error has occurred; a logic 1 mean s that a time out error has been detected. this bit is cleared by a reset. if the timeout_select bit (bit 4 of the pa rallel port mode register 2, 0xf1 in logical device
smsc ds ? LPC47M15X page 84 rev. 08/02/2001 3 configuration registers) is ?0?, writing a one to this bit clears the tmout status bit. writing a zero to this bit has no effect. if the timeout_select bit (bit 4 of the paralle l port mode register 2, 0xf1 in logical device 3 configuration registers) is ?1?, the tmout bit is cleared on the trailing edge of a read of the epp status register. bits 1, 2 - are not implemented as register bits, during a read of the printer stat us register these bits are a low level. bit 3 nerr ? nerror the level on the nerror input is read by the cpu as bit 3 of the printer status register . a logic 0 means an error has been detected; a logic 1 means no error has been detected. bit 4 slt - printer selected status the level on the slct input is read by the cpu as bit 4 of the printer status register. a logic 1 means the printer is on line; a logic 0 means it is not selected. bit 5 pe - paper end the level on the pe input is read by the cpu as bit 5 of the printer status register. a logic 1 indicates a paper end; a logic 0 indicates the presence of paper. bit 6 nack - acknowledge the level on the nack input is read by the cpu as bit 6 of the printer status register . a logic 0 means that the printer has received a character and can now accept another . a logic 1 means that it is still processing the last character or has not received the data. bit 7 nbusy - nbusy the complement of the level on the busy input is read by t he cpu as bit 7 of the printer status register. a logic 0 in this bit means that the printer is busy and cannot accept a new character. a l ogic 1 means that it is ready to accept the next character. control port address offset = 02h the control port is located at an offset of ?02h? from the base address. the control register is initialized by the reset input, bits 0 to 5 only being affected; bits 6 and 7 are hard wired low. bit 0 strobe - strobe this bit is inverted and out put onto the nstrobe output. bit 1 autofd - autofeed this bit is inverted and output onto the nautofd output. a logi c 1 causes the printer to generate a line feed after each line is printed. a logic 0 means no autofeed. bit 2 ninit - initiate output this bit is output onto the ni nit output without inversion. bit 3 slctin - printer select input this bit is inverted and output onto the nslctin output. a l ogic 1 on this bit selects the printer; a logic 0 means the printer is not selected. bit 4 irqe - interrupt request enable the interrupt request enable bit when set to a high level may be used to enable interrupt requests from the parallel port to the cpu. an interrupt request is generated on the irq port by a positive going nack input. when the irqe bit is programmed low the irq is disabled. bit 5 pcd - parallel control direction parallel control direction is not valid in printer mode. in printer mode, the direction is always out regardless of the state of this bit. in bi-directional, epp or ecp mode, a l ogic 0 means that the printer por t is in output mode (write); a logic 1 means that the printer port is in input mode (read). bits 6 and 7 during a read are a low level, and cannot be written.
smsc ds ? LPC47M15X page 85 rev. 08/02/2001 epp address port address offset = 03h the epp address port is located at an offset of ?03h? from the base address. the address register is cleared at initialization by reset. during a write operation, the content s of the internal data bus db0-db7 are buffered (non inverting) and output onto the pd0 - pd7 ports. an lpc i/o write cycle causes an epp address write cycle to be performed, during which the data is latc hed for the duration of the epp write cycl e. during a read operation, pd0 - pd7 ports are read. an lpc i/o read cycle causes an epp address read cycle to be performed and the data output to the host cpu, the deassertion of addrstb latches the pdata for the duration of the read cycle. this register is only available in epp mode. epp data port 0 address offset = 04h the epp data port 0 is located at an offset of ?04h? from the base address. the data register is cleared at initialization by reset. during a write operation, the content s of the internal data bus db0-db7 are buffered (non inverting) and output onto the pd0 - pd7 ports. an lpc i/o write cycle causes an epp data write cycle to be performed, during which the data is latc hed for the duration of the epp write cycl e. during a read operation, pd0 - pd7 ports are read. an lpc i/o read cycle causes an epp read cycle to be performed and the data output to the host cpu, the deassertion of datastb latc hes the pdata for the duration of the read cycle. this register is only available in epp mode. epp data port 1 address offset = 05h the epp data port 1 is located at an offset of ?05h? from t he base address. refer to epp data port 0 for a description of operation. this regist er is only available in epp mode. epp data port 2 address offset = 06h the epp data port 2 is located at an offset of ?06h? from t he base address. refer to epp data port 0 for a description of operation. this regist er is only available in epp mode. epp data port 3 address offset = 07h the epp data port 3 is located at an offset of ?07h? from t he base address. refer to epp data port 0 for a description of operation. this regist er is only available in epp mode. epp 1.9 operation when the epp mode is selected in the configuration register, the standard and bi-directional modes are also available. if no epp read, write or address cycle is current ly executing, then the pdx bus is in the standard or bi- directional mode, and all output signals (strobe, autofd , init) are as set by the spp control port and direction is controlled by pcd of the control port. in epp mode, the system timing is closel y coupled to the epp timing. for this reason, a watchdog timer is required to prevent system lockup. the timer indicates if more th an 10usec have elapsed from the start of the epp cycle to nwait being deasserted (after command). if a time-out oc curs, the current epp cycle is aborted and the time-out condition is indicated in status bit 0. during an epp cycle, if strobe is ac tive, it overrides the epp write signal fo rcing the pdx bus to always be in a write mode and the nwrite signal to always be asserted.
smsc ds ? LPC47M15X page 86 rev. 08/02/2001 software constraints before an epp cycle is executed, the software must ensure t hat the control register bit pcd is a logic ?0? (i.e., a 04h or 05h should be written to the control port). if the user leaves pcd as a logic ?1?, and attempts to perform an epp write, the chip is unable to perform the write (because pcd is a logic ?1?) and will appear to perform an epp read on the parallel bus, no error is indicated. epp 1.9 write the timing for a write operati on (address or data) is shown in timing diagram epp write data or address cycle. the chip inserts wait states into the lpc i/o write cycle until it has been determined that the writ e cycle can complete. the write cycle can complete under the following circumstances: 1) if the epp bus is not ready (nwait is active low) when ndatastb or naddrstb goes active then the write can complete when nwait goes inactive high. 2) if the epp bus is ready (nwait is inactive high) then the chip must wait for it to go active low before changing the state of ndatastb, nwrite or naddrstb. the wr ite can complete once nwait is determined inactive. write sequence of operation 1) the host initiates an i/o write cycl e to the selected epp register. 2) if wait is not asserted, the chip must wait until wait is asserted. 3) the chip places address or data on pdata bus, clears pdir, and asserts nwrite. 4) chip asserts ndatastb or naddrstrb indicating that pdata bus contains valid information, and the write signal is valid. 5) peripheral deasserts nwait, indicating that any setup requirements have been satisfied and the chip may begin the termination phase of the cycle. 6) a) the chip deasserts ndatastb or naddrstrb, this ma rks the beginning of the termination phase. if it has not already done so, the peripheral should latch the information byte now. b) the chip latches the data from the internal data bus for the pdata bus and drives the sync that indicates that no more wait states are required followed by the tar to complete the write cycle. 7) peripheral asserts nwait, indicating to the host th at any hold time requirements have been satisfied and acknowledging the termination of the cycle. 8) chip may modify nwrite and npdata in preparation for the next cycle. epp 1.9 read the timing for a read operation (data) is shown in timing diagram epp read data cycle. the chip inserts wait states into the lpc i/o read cycle until it has been determined t hat the read cycle can complete. the read cycle can complete under the following circumstances: 1) if the epp bus is not ready (nwait is active low) when ndatastb goes active then the read can complete when nwait goes inactive high. 2) if the epp bus is ready (nwait is inactive high) then the chip must wait for it to go active low before changing the state of nwrite or before ndatastb goes active. the read can complete once nwait is determined inactive. read sequence of operation 1) the host initiates an i/o read cycle to the selected epp register. 2) if wait is not asserted, the chip must wait until wait is asserted. 3) the chip tri-states the pdata bus and deasserts nwrite. 4) chip asserts ndatastb or naddrstrb indicating that pdata bus is tri-stated, pdir is set and the nwrite signal is valid. 5) peripheral drives pdata bus valid. 6) peripheral deasserts nwait, indicating that pdata is valid and the chip may begin the termination phase of the cycle. 7) a) the chip latches the data from the pdata bus for the internal data bus and deasserts ndatastb or naddrstrb. this marks the begi nning of the termination phase. b) the chip drives the sync that indicates that no more wait states are required and drives valid data onto the lad[3:0] signals, followed by the tar to complete the read cycle. 8) peripheral tri-states the pdata bus and asserts nwait, indicating to the host that the pdata bus is tri-stated. 9) chip may modify nwrite, pdir and npdata in preparation for the next cycle.
smsc ds ? LPC47M15X page 87 rev. 08/02/2001 epp 1.7 operation when the epp 1.7 mode is selected in the configuration register, the standar d and bi-directional modes are also available. if no epp read, write or address cycle is current ly executing, then the pdx bus is in the standard or bi- directional mode, and all output signals (strobe, autofd , init) are as set by the spp control port and direction is controlled by pcd of the control port. in epp mode, the system timing is closel y coupled to the epp timing. for this reason, a watchdog timer is required to prevent system lockup. the timer indicates if more th an 10usec have elapsed from the start of the epp cycle to the end of the cycle. if a time-out o ccurs, the current epp cycle is aborted and th e time-out condition is indicated in status bit 0. software constraints before an epp cycle is executed, the software must ensure that the control register bits d0, d1 and d3 are set to zero. also, bit d5 (pcd) is a logic ?0? fo r an epp write or a logic ?1? for and epp read. epp 1.7 write the timing for a write operati on (address or data) is shown in timing diag ram epp 1.7 write data or address cycle. the chip inserts wait states into the i/o write cycle when nw ait is active low during the epp cycle. this can be used to extend the cycle time. the write cycle c an complete when nwai t is inactive high. write sequence of operation 1) the host sets pdir bit in the control regist er to a logic ?0?. this asserts nwrite. 2) the host initiates an i/o write cy cle to the selected epp register. 3) the chip places address or data on pdata bus. 4) chip asserts ndatastb or naddrstrb indicating that pdata bus contains valid information, and the write signal is valid. 5) if nwait is asserted, the chip inse rts wait states into i/o write cycle unt il the peripheral deasserts nwait or a time-out occurs. 6) the chip drives the final sync, deasserts ndatastb or naddrstrb and latches the data from the internal data bus for the pdata bus. 7) chip may modify nwrite, pdir and npdata in preparation of the next cycle. epp 1.7 read the timing for a read operation (data) is shown in timing diagram epp 1.7 read data cycle. the chip inserts wait states into the i/o read cycle when nwait is active low during the epp cycle. this can be used to extend the cycle time. the read cycle can complete when nwait is inactive high. read sequence of operation 1) the host sets pdir bit in the control register to a logic ?1?. this deasserts nw rite and tri-states the pdata bus. 2) the host initiates an i/o read cy cle to the selected epp register. 3) chip asserts ndatastb or naddrstrb indicating that pdata bus is tri-stated, pdir is set and the nwrite signal is valid. 4) if nwait is asserted, the chip inse rts wait states into the i/o read cycle until the peripheral deasserts nwait or a time-out occurs. 5) the peripheral drives pdata bus valid. 6) the peripheral deasserts nwait, indicating that pdata is valid and the chip may begin the termination phase of the cycle. 7) the chip drives the final sync and deasserts ndatastb or naddrstrb. 8) peripheral tri-states the pdata bus. 9) chip may modify nwrite, pdir and npda ta in preparation of the next cycle. table 40 ? epp pin descriptions epp signal epp name type epp description nwrite nwrite o this signal is active low. it denotes a write operation. pd<0:7> address/data i/o bi -directional epp byte wi de address and data bus. intr interrupt i this signal is active high and positive edge triggered. (pass through with no inversion, same as spp).
smsc ds ? LPC47M15X page 88 rev. 08/02/2001 epp signal epp name type epp description nwait nwait i this signal is active low. it is driven inactive as a positive acknowledgement from the device that the transfer of data is completed. it is driven active as an indication that the device is ready for the next transfer. ndatastb ndata strobe o this signal is active low. it is used to denote data read or write operation. nreset nreset o this signal is active low. when driven active, the epp device is reset to its initial operational mode. naddrstb address strobe o this signal is active low. it is used to denote address read or write operation. pe paper end i same as spp mode. slct printer selected status i same as spp mode. nerr error i same as spp mode. note 1: spp and epp can use 1 common register. note 2: nwrite is the only epp output that can be over-ridden by spp control port during an epp cycle. for correct epp read cycles, pcd is required to be a low. 6.8.2 extended capabilities parallel port ecp provides a number of advantages, some of which are listed below. the individual features are explained in greater detail in the remainder of this section. high performance half-duplex forward and reverse channel in terlocked handshake, for fast reliable transfer optional single byte rle compression for improved throughput (64:1) channel addressing for low-cost peripherals maintains link and data layer separation permits the use of active output drivers permits the use of adaptive signal timing peer-to-peer capability. vocabulary the following terms are used in this document: assert: when a signal asserts it transitions to a "true" state, when a signal deasserts it transitions to a "false" state. forward: host to peripheral communication. reverse: peripheral to host communication pword: a port word; equal in size to the width of the lpc interface. for this implementation, pword is always 8 bits. 1 a high level. 0 a low level. these terms may be considered synonymous: periphclk, nack hostack, nautofd periphack, busy nperiphrequest, nfault nreverserequest, ninit nackreverse, perror xflag, select ecpmode, nselectln hostclk, nstrobe reference document: ieee 1284 extended capabilit ies port protocol and isa interface standard , rev 1.14, july 14, 1993. this document is available from microsoft. the bit map of the extended parallel port registers is: d7 d6 d5 d4 d3 d2 d1 d0 note data pd7 pd6 pd5 pd 4 pd3 pd2 pd1 pd0 ecpafifo addr/rle address or rle field 2
smsc ds ? LPC47M15X page 89 rev. 08/02/2001 dsr nbusy nack perror select nfault 0 0 0 1 dcr 0 0 direction ackinten selecti n ninit autofd strobe 1 cfifo parallel port data fifo 2 ecpdfifo ecp data fifo 2 tfifo test fifo 2 cnfga 0 0 0 1 0 0 0 0 cnfgb compress intrvalue parallel port irq parallel port dma ecr mode nerrintre n dmaen serviceintr full empty note 1: these registers are available in all modes. note 2: all fifos use one common 16 byte fifo. note 3: the ecp parallel port config reg b reflects the irq and dma channel selected by the configuration registers. ecp implementation standard this specification describes the standard interface to the extended capa bilities port (ecp). all lpc devices supporting ecp must meet the requirement s contained in this section or the port will not be supported by microsoft. for a description of the ecp protocol, please refer to t he ieee 1284 extended capabilities port protocol and isa interface standard , rev. 1.14, july 14, 1993. this doc ument is available from microsoft. description the port is software and hardware compatible with existing parallel ports so that it ma y be used as a standard lpt port if ecp is not required. the port is designed to be simple and requires a small number of gates to implement. it does not do any ?protocol? negotiation, rather it provides an automatic high burst-bandwi dth channel that supports dma for ecp in both the forward and reverse directions. small fifos are employed in both forward and reverse di rections to smooth data flow and improve the maximum bandwidth requirement. the size of the fifo is 16 byte s deep. the port supports an automatic handshake for the standard parallel port to improve co mpatibility mode transfer speed. the port also supports run length encoded (rle) decompression (required) in hardware. compression is accomplished by counting identical bytes and transmitting an rl e byte that indicates how ma ny times the next byte is to be repeated. decompression simply intercepts the rle byte and repeats the following byte the specified number of times. hardware support for compression is optional. table 41 ? ecp pin descriptions name type description nstrobe o during write operations nstrobe registers data or address into the slave on the asserting edge (handshakes with busy). pdata 7:0 i/o contains addr ess or data or rle data. nack i indicates valid data driven by the per ipheral when asserted. this signal handshakes with nautofd in reverse. periphack (busy) i this signal deasserts to indicate that the peripheral can accept data. this signal handshakes with nstrobe in the forward direction. in the reverse direction this signal indicates whether the data lines contain ecp command information or data. the peripheral uses this signal to flow control in the forward direction. it is an ?interlocked? handshake with nstrobe. periphack also provides command information in the reverse direction. perror (nackreverse) i used to acknowledge a change in the direction the transfer (asserted = forward). the peripheral drives this signal low to acknowledge nreverserequest. it is an ?interlocked? handshake with nreverserequest. the host relies upon nackreverse to determine when it is permitted to drive the data bus. select i indicates printer on line.
smsc ds ? LPC47M15X page 90 rev. 08/02/2001 name type description nautofd (hostack) o requests a byte of data from the peripheral when asserted, handshaking with nack in the reverse direction. in the forward direction this signal indicates whether the data lines contain ecp address or data. the host drives this signal to flow control in the reverse direction. it is an ?interlocked? handshake with nack. hostack also provides command information in the forward phase. nfault (nperiphrequest) i generates an error interrupt when asserted. this signal provides a mechanism for peer-to-peer communication. this signal is valid only in the forward direction. during ec p mode the peripheral is permitted (but not required) to drive this pin low to request a reverse transfer. the request is merely a ?hint? to the host; the host has ultimate control over the transfer direction. this signal would be typically used to generate an interrupt to the host cpu. ninit o sets the transfer direction (asserted = reverse, deasserted = forward). this pin is driven low to place the ch annel in the reverse direction. the peripheral is only allowed to drive the bi-directional data bus while in ecp mode and hostack is low and nselectin is high. nselectin o always deasserted in ecp mode. register definitions the register definitions are based on the standard ibm addre sses for lpt. all of the standard printer ports are supported. the additional registers attach to an upper bit decode of the standard lpt port definition to avoid conflict with standard isa devices. the port is equivalent to a gener ic parallel port interface and may be operated in that mode. the port registers vary depending on the mode fiel d in the ecr. the table below lists these dependencies. operation of the devices in modes other that thos e specified is undefined. table 42 ? ecp register definitions name address (note 1) ecp modes function data +000h r/w 000-001 data register ecpafifo +000h r/w 011 ecp fifo (address) dsr +001h r/w all status register dcr +002h r/w all control register cfifo +400h r/w 010 parallel port data fifo ecpdfifo +400h r/w 011 ecp fifo (data) tfifo +400h r/w 110 test fifo cnfga +400h r 111 configuration register a cnfgb +401h r/w 111 configuration register b ecr +402h r/w all extended control register note 1: these addresses are added to the parallel port base address as selected by configuration register or jumpers. note 2: all addresses are qualified with aen. refer to the aen pin definition. table 43 ? mode descriptions mode description* 000 spp mode 001 ps/2 parallel port mode 010 parallel port data fifo mode 011 ecp parallel port mode 100 epp mode (if this option is enabled in the configuration registers) 101 reserved 110 test mode 111 configuration mode *refer to ecr register description
smsc ds ? LPC47M15X page 91 rev. 08/02/2001 data and ecpafifo port address offset = 00h modes 000 and 001 (data port) the data port is located at an offset of ?00h? from the base address. the data register is cleared at initialization by reset. during a write operation, the data register latc hes the contents of the data bus. the contents of this register are buffered (non inverting) and output onto the pd0 - pd7 ports. during a read operation, pd0 - pd7 ports are read and output to the host cpu. mode 011 (ecp fifo - address/rle) a data byte written to this address is placed in the fi fo and tagged as an ecp addre ss/rle. the hardware at the ecp port transmits this byte to the peripheral automatically . the operation of this regi ster is only defined for the forward direction (direction is 0). refer to the ecp para llel port forward timing diagram, located in the timing diagrams section of this data sheet . device status register (dsr) address offset = 01h the status port is located at an offset of ?01h? from the base address. bits0 - 2 are not implemented as register bits, during a read of the printer status regi ster these bits are a low level. the bits of the status port are defined as follows: bit 3 nfault the level on the nfault input is read by the cpu as bit 3 of the device status register. bit 4 select the level on the select input is read by the cpu as bit 4 of the device status register. bit 5 perror the level on the perror input is read by the cpu as bit 5 of the device status register. printer status register. bit 6 nack the level on the nack input is read by the cpu as bit 6 of the device status register. bit 7 nbusy the complement of the level on the busy input is read by the cpu as bit 7 of the device status register. device control register (dcr) address offset = 02h the control register is located at an offset of ?02h? from th e base address. the control register is initialized to zero by the reset input, bits 0 to 5 only being affected; bits 6 and 7 are hard wired low. bit 0 strobe - strobe this bit is inverted and out put onto the nstrobe output. bit 1 autofd - autofeed this bit is inverted and output onto the nautofd output. a logi c 1 causes the printer to generate a line feed after each line is printed. a logic 0 means no autofeed. bit 2 ninit - initiate output this bit is output onto the ni nit output without inversion.
smsc ds ? LPC47M15X page 92 rev. 08/02/2001 bit 3 selectin this bit is inverted and output onto the nslctin output. a l ogic 1 on this bit selects the printer; a logic 0 means the printer is not selected. bit 4 ackinten - interrupt request enable the interrupt request enable bit when set to a high level may be used to enable interrupt requests from the parallel port to the cpu due to a low to high transition on the nack input. refer to the description of the interrupt under operation, interrupts. bit 5 direction if mode=000 or mode=010, this bit has no effect and the directi on is always out regardless of the state of this bit. in all other modes, direction is valid and a logic 0 means that the printer port is in output mode (write); a logic 1 means that the printer port is in input mode (read). bits 6 and 7 during a read are a low level, and cannot be written. cfifo (parallel port data fifo) address offset = 400h mode = 010 bytes written or dmaed from the system to this fifo are transmitted by a hardware handshake to the peripheral using the standard parallel port protocol. transfers to the fifo are byte aligned. this mode is only defined for the forward direction. ecpdfifo (ecp data fifo) address offset = 400h mode = 011 bytes written or dmaed from the system to this fifo, w hen the direction bit is 0, are transmitted by a hardware handshake to the peripheral using the ecp parallel port protocol. transfers to the fifo are byte aligned. data bytes from the peripheral are re ad under automatic hardware handshake from ecp into this fifo when the direction bit is 1. reads or dmas from the fi fo will return bytes of ecp data to the system. tfifo (test fifo mode) address offset = 400h mode = 110 data bytes may be read, written or dmaed to or from the system to this fifo in any direction. data in the tfifo will not be transmitted to the to the parallel port lines using a hardware protocol ha ndshake. however, data in the tfifo may be displayed on the parallel port data lines. the tfifo will not stall when overwritten or underrun. if an attempt is made to write data to a full tfifo, the new data is not accepted into the tfifo. if an attempt is made to read data from an empty tfifo, the last data byte is re-read again. the full and empty bits must always keep track of the correct fifo state. the tf ifo will transfer data at the maximum isa rate so that software may generate performance metrics. the fifo size and interrupt threshold can be determined by writing bytes to the fifo and checking the full and serviceintr bits. the writeintrthreshold can be determined by starting with a full tfifo, setting the direction bit to 0 and emptying it a byte at a time until serviceintr is set. this may generate a spurious interrupt, but will indicate that the threshold has been reached. the readintrthreshold can be determined by setting the direct ion bit to 1 and filling the empty tfifo a byte at a time until serviceintr is set. this may generat e a spurious interrupt, but will indicate that the threshold has been reached. data bytes are always read from the head of tfifo regardle ss of the value of the direct ion bit. for example if 44h, 33h, 22h is written to the fifo, then reading the tfifo will return 44h, 33h, 22h in the same order as was written.
smsc ds ? LPC47M15X page 93 rev. 08/02/2001 cnfga (configuration register a) address offset = 400h mode = 111 this register is a read only register. when read, 10h is returned. this indicates to the system that this is an 8-bit implementation. (pword = 1 byte) cnfgb (configuration register b) address offset = 401h mode = 111 bit 7 compress this bit is read only. during a read it is a low level. this means that this chip does not support hardware rle compression. it does support hardware de-compression. bit 6 intrvalue returns the value of the interrupt to determine possible conflicts. bit [5:3] parallel port irq (read-only) to table 44b bits [2:0] parallel port dma (read-only) to table 44c ecr (extended control register) address offset = 402h mode = all this register controls the ex tended ecp parallel port functions. bits 7,6,5 these bits are read/write and select the mode. bit 4 nerrintren read/write (valid only in ecp mode) 1: disables the interrupt generat ed on the asserting edge of nfault. 0: enables an interrupt pulse on the hi gh to low edge of nfault. note that an interrupt will be generated if nfault is asserted (interrupting) and this bit is written from a 1 to a 0. this prevents interrupts from being lost in the time between the read of the ecr and the write of the ecr. bit 3 dmaen read/write 1: enables dma (dma starts when serviceintr is 0). 0: disables dma unconditionally. bit 2 serviceintr read/write 1: disables dma and all of the service interrupts. 0: enables one of the following 3 cases of interrupt s. once one of the 3 service interrupts has occurred serviceintr bit shall be set to a 1 by hardware. it must be re set to 0 to re-enable the inte rrupts. writing this bit to a 1 will not cause an interrupt. case dmaen=1: during dma (this bit is set to a 1 when terminal count is reached). case dmaen=0 direction=0:
smsc ds ? LPC47M15X page 94 rev. 08/02/2001 this bit shall be set to 1 whenever there are writeintrthreshold or more bytes free in the fifo. case dmaen=0 direction=1: this bit shall be set to 1 whenever there are readintrt hreshold or more valid bytes to be read from the fifo. bit 1 full read only 1: the fifo cannot accept another byte or the fifo is completely full. 0: the fifo has at least 1 free byte. bit 0 empty read only 1: the fifo is completely empty. 0: the fifo contains at least 1 byte of data. table 44a ? extended control register r/w mode 000: standard parallel port mode . in this mode t he fifo is reset and common drain drivers are used on the control lines (nstr obe, nautofd, ninit and nselectin). setting the direction bit will not tri-state the output drivers in this mode. 001: ps/2 parallel port mode. same as above except t hat direction may be used to tri-state the data lines and reading the data register return s the value on the data lines and not the value in the data register. all driver s have active pull-ups (push-pull). 010: parallel port fifo mode. this is the same as 000 except that bytes are written or dmaed to the fifo. fifo data is automatically transmi tted using the standard parallel port protocol. note that this mode is only useful when direct ion is 0. all drivers have active pull-ups (push-pull). 011: ecp parallel port mode. in the forward direct ion (direction is 0) bytes placed into the ecpdfifo and bytes written to the ecpafifo are placed in a single fifo and transmitted automatically to the peripheral using ecp protoc ol. in the reverse direction (direction is 1) bytes are moved from the ecp parallel port and packed into bytes in the ecpdfifo. all drivers have active pull-ups (push-pull). 100: selects epp mode: in this mode, epp is selected if the epp supported option is selected in configuration register l3- crf0. all drivers have active pull-ups (push-pull). 101: reserved 110: test mode. in this mode the fifo may be written and read, but the data will not be transmitted on the parallel port. all driv ers have active pull-ups (push-pull). 111: configuration mode. in this mode the confga, confgb registers are accessible at 0x400 and 0x401. all drivers have active pull-ups (push-pull). table 44b table 44c irq selected config reg b bits 5:3 dma selected config reg b bits 2:0 15 110 3 011 14 101 2 010 11 100 1 001 10 011 all others 000 9 010 7 001 5 111 all others 000
smsc ds ? LPC47M15X page 95 rev. 08/02/2001 operation mode switching/software control software will execute p1284 negotia tion and all operation prior to a data transfer phase under programmed i/o control (mode 000 or 001). hardware provides an automati c control line handshake, moving data between the fifo and the ecp port only in the data tr ansfer phase (modes 011 or 010). setting the mode to 011 or 010 will cause the hardware to initiate data transfer. if the port is in mode 000 or 001 it may switch to any other mode. if the port is not in mode 000 or 001 it can only be switched into mode 000 or 001. the dire ction can only be changed in mode 001. once in an extended forward mode the software should wait for the fifo to be empty before switching back to mode 000 or 001. in this case all control signals will be deasserted before the mode switch. in an ecp reverse mode the software waits for all the data to be read from the fi fo before changing back to mode 000 or 001. since the automatic hardware ecp reverse handshak e only cares about the stat e of the fifo it may have acquired extra data which will be discarded. it may in fact be in the middle of a transfer when the mode is changed back to 000 or 001. in this case the port will deassert nautofd independent of th e state of the transfer. the des ign shall not cause glitches on the handshake signals if the soft ware meets the constraints above. ecp operation prior to ecp operation the host must negotiate on the paralle l port to determine if the peripheral supports the ecp protocol. this is a somewhat complex negotiati on carried out under program control in mode 000. after negotiation, it is necessary to initialize some of the port bits. the following are required: set direction = 0, enabling the drivers. set strobe = 0, causing the nstrobe sign al to default to the deasserted state. set autofd = 0, causing the nautofd si gnal to default to the deasserted state. set mode = 011 (ecp mode) ecp address/rle bytes or data bytes may be sent automatica lly by writing the ecpafifo or ecpdfifo respectively. note that all fifo data transfers are byte wide and byte aligned. address/rle transfers are byte-wide and only allowed in the forward direction. the host may switch directions by first switching to mo de = 001, negotiating for the forward or reverse channel, setting direction to 1 or 0, then setting mode = 011. when di rection is 1 the hardware shall handshake for each ecp read data byte and attempt to fill the fifo. bytes may then be read from the ecpdfifo as long as it is not empty. ecp transfers may also be accomplished (albeit slowly) by handshaking individual bytes under program control in mode = 001, or 000. termination from ecp mode termination from ecp mode is similar to the termination from nibble/byte modes. the host is permitted to terminate from ecp mode only in specific well-defined states. t he termination can only be executed while the bus is in the forward direction. to terminate while the channel is in the reverse direction, it must first be transitioned into the forward direction. command/data ecp mode supports two advanced features to improve the effe ctiveness of the protocol for some applications. the features are implemented by allo wing the transfer of normal 8 bit data or 8 bit commands. when in the forward direction, normal data is transferred when hostack is high and an 8 bit command is transferred when hostack is low. the most significant bit of the command indicates whether it is a run-length count (for compression) or a channel address. when in the reverse direction, normal data is transferred when periphack is high and an 8 bit command is transferred when periphack is low. the most significant bit of the command is always zero. reverse channel addresses are seldom used and may not be supported in hardware.
smsc ds ? LPC47M15X page 96 rev. 08/02/2001 table 45 ? channel/data commands supported in ecp mode forward channel commands (hostack low) reverse channel commands (peripack low) d7 d[6:0] 0 run-length count (0-127) (mode 0011 0x00 only) 1 channel address (0-127) data compression the ecp port supports run length encoded (rle) decompression in hardware and can transfer compressed data to a peripheral. run length encoded (rle) compression in hardware is not supported. to transfer compressed data in ecp mode, the compression count is written to the ecpa fifo and the data byte is written to the ecpdfifo. compression is accomplished by counting identical bytes and transmitting an rle byte that indicates how many times the next byte is to be repeated. decompression simp ly intercepts the rle byte and repeats the following byte the specified number of times. when a run-length count is received from a peripheral, the subsequent data byte is replicated the specified number of ti mes. a run-length count of zero spec ifies that only one byte of data is represented by the next data byte, whereas a run-length count of 127 indicates that the next byte should be expanded to 128 bytes. to prevent data expansion, howe ver, run-length counts of zero should be avoided. pin definition the drivers for nstrobe, naut ofd, ninit and nselectin are open-drain in mode 000 and are push-pull in all other modes. lpc connections the interface can never stall causing t he host to hang. the width of data trans fers is strictly controlled on an i/o address basis per this specification. a ll fifo-dma transfers are byte wide, byte aligned and end on a byte boundary. (the pword value can be obtained by reading configuration re gister a, cnfga, described in the next section). single byte wide transfers are always possible with stan dard or ps/2 mode using program control of the control signals. interrupts the interrupts are enabled by servic eintr in the ecr register. serviceintr = 1 disables the dma and all of the service interrupts. serviceintr = 0 enables the selected interrupt condition. if the interrupting condition is valid, then the interrupts generated immediately when this bit is changed from a 1 to a 0. this can occur during programmed i/o if the number of bytes removed or added from/to the fifo does not cross the threshold. an interrupt is generated when: 1) for dma transfers: when serviceintr is 0, dm aen is 1 and the dma tc cycle is received. 2) for programmed i/o: a) when serviceintr is 0, dmaen is 0, direction is 0 and there are writeint rthreshold or more free bytes in the fifo. also, an interrupt is generated when serviceintr is cleared to 0 whenever there are writeintrthreshold or more free bytes in the fifo. b) when serviceintr is 0, dmaen is 0, direction is 1 and there are readintrthreshold or more bytes in the fifo. also, an interrupt is generated when serviceintr is cleared to 0 whenever there are readintrthreshold or more bytes in the fifo. 3) when nerrintren is 0 and nfault transit ions from high to low or when nerrintren is set from 1 to 0 and nfault is asserted. 4) when ackinten is 1 and the nack signal transitions from a low to a high. fifo operation the fifo threshold is set in the chip configuration regist ers. all data transfers to or from the parallel port can proceed in dma or programmed i/o (non-dma) mode as indi cated by the selected mode. the fifo is used by selecting the parallel port fifo mode or ecp parallel po rt mode. (fifo test mode will be addressed separately.) after a reset, the fifo is disabled. each data byte is transferred by a programmed i/o cycle or dma cycle depending on the selection of dma or programmed i/o mode.
smsc ds ? LPC47M15X page 97 rev. 08/02/2001 the following paragraphs detail the operation of the fifo fl ow control. in these descr iptions, ranges from 1 to 16. the parameter fifothr, which the user programs, is one less and ranges from 0 to 15. a low threshold value (i.e. 2) results in longer periods of time between service requests, but requires faster servicing of the request for both read and write cases. the host must be very responsive to the service request. this is the desired case for use with a ?fast? system. a high value of threshold (i.e. 12) is used with a ?sluggish? system by affording a long latency period after a service requ est, but results in more frequent service requests. dma transfers dma transfers are always to or from the ecpdfifo, tfifo or cfifo. dma utilizes the standard pc dma services. to use the dma transfers, the host first sets up the direction and state as in the progra mmed i/o case. then it programs the dma controller in the host with the desired count and me mory address. lastly it sets dmaen to 1 and serviceintr to 0. the ecp requests dma transfers from the host by encoding the nldrq pin. th e dma will empty or fill the fifo using the appropriate direction and mode. when the terminal count in the dma controller is reached, an interrupt is generated and serviceintr is asserted, disabling dma. in order to prevent possible blocking of refresh requests a dma cycle shall not be requested for more than 32 dma cycles in a row. the fifo is enabled directly by the host initiating a dma cycle for the requested channel, and addresses need not be valid. an interrupt is generated when a tc cycle is received. (note: the only way to properly terminate dma transfers is with a tc cycle.) dma may be disabled in the middle of a transfer by first di sabling the host dma controller. then setting serviceintr to 1, followed by setting dmaen to 0, and waiting for t he fifo to become empty or full. restarting the dma is accomplished by enabling dma in the host, setting dmae n to 1, followed by setting serviceintr to 0. dma mode - transfers from the fifo to the host (note: in the reverse mode, the peripheral may not continue to fill the fifo if it runs out of data to transfer, even if the chip continues to request more data from the peripheral.) the ecp requests a dma cycle whenever t here is data in the fifo. the dma cont roller must respond to the request by reading data from the fifo. the ecp stops requesting dma cycles when the fifo becomes empty or when a tc cycle is received, indicating that no more data is requir ed. if the ecp stops requesting dma cycles due to the fifo going empty, then a dma cycle is requested again as soon as there is one byte in the fifo. if the ecp stops requesting dma cycles due to the tc cycle, then a dma cycl e is requested again when there is one byte in the fifo, and serviceintr has been re-enabled. programmed i/o mode or non-dma mode the ecp or parallel port fifos may al so be operated using interrupt driven programmed i/o. software can determine the writeintrthreshold, readintrthreshold, and fi fo depth by accessing the fifo in test mode. programmed i/o transfers are to the ecpdfifo at 400h and ecpafifo at 000h or from the ecpdfifo located at 400h, or to/from the tfifo at 400h. to use the programmed i/o transfers, the host first sets up the directi on and state, sets dmaen to 0 and serviceintr to 0. the ecp requests programmed i/o transfers from the host by activating the interrupt. the programmed i/o will empty or fill the fifo using the ap propriate direction and mode. note: a threshold of 16 is equivalent to a threshold of 15. these two cases are treated the same. programmed i/o - transfers from the fifo to the host in the reverse direction an interrupt occurs when servicei ntr is 0 and readintrthreshold bytes are available in the fifo. if at this time the fifo is full it can be emptied completely in a single burst, otherwise readintrthreshold bytes may be read from the fifo in a single burst. readintrthreshold =(16-) data bytes in fifo an interrupt is generated when serviceintr is 0 and the num ber of bytes in the fifo is greater than or equal to (16- ). (if the threshold = 12, t hen the interrupt is set whenever there ar e 4-16 bytes in the fifo). the host must respond to the request by reading data from the fifo. this process is repeated until the last byte is transferred out of the fifo. if at this time the fifo is full, it can be completely emptied in a single burst, otherwise a minimum of (16-) bytes may be read from the fifo in a single burst.
smsc ds ? LPC47M15X page 98 rev. 08/02/2001 programmed i/o - transfers from the host to the fifo in the forward direction an interrupt occurs when servicei ntr is 0 and there are writeint rthreshold or more bytes free in the fifo. at this time if the fifo is empty it c an be filled with a single burst before the empty bit needs to be re-read. otherwise it may be filled with writeintrthreshold bytes. writeintrthreshold = (16-) free bytes in fifo an interrupt is generated when servicei ntr is 0 and the number of bytes in the fifo is less than or equal to . (if the threshold = 12, then the interrupt is set whenever there are 12 or less bytes of data in the fifo.) the host must respond to the request by writing data to the fifo. if at this time the fifo is empty, it can be completely filled in a single burst, otherwise a minimum of (16-) bytes may be written to the fifo in a single burst. this process is repeated until t he last byte is transferred into the fifo. 6.9 power management power management capabilities are provided for the follow ing logical devices: floppy disk, uart 1, uart 2 and the parallel port. for each logical device, two types of powe r management are provided: direct powerdown and auto powerdown. fdc power management direct power management is controlled by cr 22. refer to cr22 fo r more information. auto power management is enabled by cr23-b0. when set, this bit allows fdc to enter powerdown when all of the following conditions have been met: 1) the motor enable pins of register 3f2h are inactive (zero). 2) the part must be idle; msr=80h and int = 0 (int ma y be high even if msr = 80h due to polling interrupts). 3) the head unload timer must have expired. 4) the auto powerdown timer (10msec) must have timed out. an internal timer is initiated as soon as the auto powerdown command is enabled. the part is then powered down when all the conditions are met. disabling the auto powerdown mode cancels the time r and holds the fdc block out of auto powerdown. note: at least 8us delay should be added when exiting fdc auto powerdown mode. if the operating environment is such that this delay cannot be guaranteed, the auto powerdown mode should not be used and direct powerdown mode should be used instead. the direct powerdown mode requires at least 8us delay at 250k bits/sec configuration and 4us delay at 500k bits/sec. the delay should be added so that the internal microcontroller can prepare itself to accept commands. dsr from powerdown if dsr powerdown is used when the part is in auto po werdown, the dsr powerdown will override the auto powerdown. however, when the part is awakened from dsr powerdown, the auto powerdown will once again become effective. wake up from auto powerdown if the part enters the powerdown state through the auto powe rdown mode, then the part can be awakened by reset or by appropriate access to certain registers. if a hardware or software reset is used then the part will go through the normal reset sequence. if the access is through the selected registers, then t he fdc resumes operation as though it was never in powerdown. besides activating the npci_reset pin or one of the software reset bits in the dor or dsr, t he following register accesses will wake up the part: 1) enabling any one of the motor enable bits in the dor register (reading the dor does not awaken the part). 2) a read from the msr register. 3) a read or write to the data register. once awake, the fdc will reinitiate the auto powerdown timer for 10 ms. the part will powerdown again when all the powerdown conditions are satisfied.
smsc ds ? LPC47M15X page 99 rev. 08/02/2001 register behavior table 46illustrates the at and ps/2 (including model 30) c onfiguration registers availabl e and the type of access permitted. in order to maintain software transparency, access to all the registers must be maintained. as table 46 shows, two sets of registers are di stinguished based on whether their access results in the part remaining in powerdown state or exiting it. access to all other registers is possible without awak ening the part. these registers can be accessed during powerdown without changing the status of the part. a read from these registers will reflect the true status as shown in the register description in the fdc description. a write to the part will resu lt in the part retaining the data and subsequently reflecting it when the part awakens. acce ssing the part during powerdown may cause an increase in the power consumption by the part. the part will revert back to its low power mode when the access has been completed. pin behavior the LPC47M15X is specifically designed for systems in whic h power conservation is a primary concern. this makes the behavior of the pins during powerdown very important. the pins of the LPC47M15X can be divided into two major categories: system interface and floppy disk drive interface. the floppy disk drive pins ar e disabled so that no power will be draw n through the part as a result of any voltage applied to the pin within the part?s power supply range. most of the system interface pins are left active to monitor system accesses that may wake up the part. table 46 ? pc/at and ps/2 available registers available registers base + address pc-at ps/2 (model 30) access permitted access to these registers does not wake up the part 00h ---- sra r 01h ---- srb r 02h dor (1) dor (1) r/w 03h --- --- --- 04h dsr (1) dsr (1) w 06h --- --- --- 07h dir dir r 07h ccr ccr w access to these registers wakes up the part 04h msr msr r 05h data data r/w note 1: writing to the dor or dsr does not wake up the part, however, writing any of the motor enable bits or doing a software reset (via dor or dsr reset bits) will wake up the part. system interface pins table 47 gives the state of the interface pins in the powerd own state. pins unaffected by the powerdown are labeled ?unchanged.? table 47 ? state of system pins in auto powerdown system pins state in auto powerdown lad[3:0] unchanged nldrq unchanged nlpcpd unchanged nlframe unchanged npci_reset unchanged pci_clk unchanged ser_irq unchanged
smsc ds ? LPC47M15X page 100 rev. 08/02/2001 fdd interface pins all pins in the fdd interface which ca n be connected directly to the floppy di sk drive itself are either disabled or tristated. pins used for local logic co ntrol or part programming are unaffected. table 48 depicts the state of the floppy disk dr ive interface pins in the powerdown state. table 48 ? state of floppy disk drive interface pins in powerdown fdd pins state in auto powerdown input pins nrdata input nwrtprt input ntrk0 input nindex input ndskchg input output pins nmtr0 tristated nds0 tristated ndir active nstep active nwdata tristated nwgate tristated nhdsel active drvden[0:1] active uart power management direct power management is controlled by cr22. refer to cr22 for more information. auto power management is enabled by cr23-b4 and b5. when set, these bits allow the following auto power management operations: 1) the transmitter enters auto powerdown when the transmit buffer and shift register are empty. 2) the receiver enters powerdown when the following conditions are all met: a) receive fifo is empty b) the receiver is waiting for a start bit. note: while in powerdown the ring indicator interrupt is still valid and transitions when the ri input changes. exit auto powerdown the transmitter exits powerdown on a write to the xmit bu ffer. the receiver exits auto powerdown when rxdx changes state. mpu-401 power management direct power management is controlled by cr22. refer to cr22 for more information. auto power management is enabled by cr23-b6. when set, this bit allows the following auto power management operations 1. the transmitter enters auto powerdown when the transmit buffer and shift register are empty 2. the receiver enters powerdown when the following conditions are all met: a. receive fifo is empty b. the receiver is waiting for a start bit. exit auto powerdown the transmitter exits powerdown on a write to the xmit bu ffer. the receiver exits auto powerdown when midi_in changes state.
smsc ds ? LPC47M15X page 101 rev. 08/02/2001 parallel port direct power management is controlled by cr 22. refer to cr22 fo r more information. auto power management is enabled by cr23-b3. when set, this bit allows the ecp or epp logical parallel port blocks to be placed into powerdown when not being used. the epp logic is in powerdown under any of the following condition 1) epp is not enabled in t he configuration register 2) epp is not selected through ecr while in ecp mode. the ecp logic is in powerdown under any of the following condition 1) ecp is not enabled in the configuration register 2) spp, ps/2 parallel port or epp mode is selected through ecr while in ecp mode. exit auto powerdown the parallel port logic can change powerdown modes when the ecp mode is changed through the ecr register or when the parallel port mode is changed through the configuration registers. 6.10 serial irq the LPC47M15X supports the serial interrupt to transmit interr upt information to the host system. the serial interrupt scheme adheres to the serial irq specif ication for pci systems, version 6.0. timing diagrams for ser_irq cycle a) start frame timing with source sampled a low pulse on irq1 rt s rt s ser_irq pci_clk host controller irq1 irq1 drive source rt none irq0 frame irq1 frame s rt irq2 frame none start start frame h sl or h 1 note: h=host control; r=recovery; t=turn -around; sl=slave control; s=sample note 1: start frame pulse can be 4-8 clo cks wide depending on the location of the device in the pci bridge hierarchy in a synchronous bridge design. b) stop frame timing with host using 17 ser_irq sampling period s rt s ser_irq pci_clk host controller irq15 driver rt none irq14 irq15 s rt iochck# none stop rt stop frame h i start next cycle 1 2 3 frame frame frame note: h=host control; r=recovery; t= turn-around; s=sample; i=idle note 1: the next ser_irq cycle?s start frame pulse may or may not start immediately after the turn-around clock of the stop frame. note 2: there may be none, one or more id le states during the stop frame. note 3: stop pulse is 2 clocks wide for quiet mode, 3 clocks wide for continuous mode.
smsc ds ? LPC47M15X page 102 rev. 08/02/2001 ser_irq cycle control there are two modes of operati on for the ser_irq start frame 1) quiet (active) mode : any device may initiate a start frame by driv ing the ser_irq low for one clock, while the ser_irq is idle. after driving low for one clock the ser_i rq must immediately be tri- stated without at any time driving high. a start frame may not be initiated while th e ser_irq is active. the ser_irq is idle between stop and start frames. the ser_irq is active between star t and stop frames. this mode of operation allows the ser_irq to be idle when there are no irq/data tr ansitions which should be most of the time. once a start frame has been initiated the host controller will take over driving the ser_irq low in the next clock and will continue driving the ser_irq low for a programmable period of three to seven clocks. this makes a total low pulse width of four to ei ght clocks. finally, the host controller will drive the ser_i rq back high for one clock, then tri-state. any ser_irq device (i.e., the LPC47M15X) which detects any transition on an irq/data line for which it is responsible must initiate a start frame in order to updat e the host controller unless t he ser_irq is already in an ser_irq cycle and the irq/data transition c an be delivered in that ser_irq cycle 2) continuous (idle) mode : only the host controller can initiate a st art frame to update irq/data line information. all other ser_irq agents become passive and may not initiate a start frame. ser_irq will be driven low for four to eight clocks by host controller. this mode has two functions. it can be used to stop or idle the ser_irq or the host controller can operate ser_irq in a continuous mode by init iating a start frame at the end of every stop frame. an ser_irq mode transition can only occur during the st op frame. upon reset, ser_irq bus is defaulted to continuous mode, therefore only the host controller can initiate the first star t frame. slaves must continuously sample the stop frames pulse width to determine the next ser_irq cycle?s mode. ser_irq data frame once a start frame has been initiated, the LPC47M15X will watch for the rising edge of the start pulse and start counting irq/data frames from there. each irq/data frame is three clocks: sample phase, recovery phase, and turn-around phase. during the sample phase the LPC47M15X must drive the ser_irq low, if and only if, its last detected irq/data value was low. if its detected irq/data va lue is high, ser_irq must be left tri-stated. during the recovery phase the LPC47M15X must driv e the ser_irq high, if and only if, it had driven the ser_irq low during the previous sample phase. during the turn-around phase the LPC47M15X must tri-state the ser_irq. the LPC47M15X will drive the ser_irq line low at the appropriat e sample point if its associated irq/data line is low, regardless of which device initiated the start frame. the sample phase for each irq/data follows the low to hi gh transition of the start frame pulse by a number of clocks equal to the irq/data frame times three, minus one. (e.g. the irq5 sample clock is the sixth irq/data frame, (6 x 3) - 1 = 17 th clock after the rising edge of the start pulse).
smsc ds ? LPC47M15X page 103 rev. 08/02/2001 ser_irq sampling periods ser_irq period signal sampled # of clocks past start 1 not used 2 2 irq1 5 3 nio_smi/irq2 8 4 irq3 11 5 irq4 14 6 irq5 17 7 irq6 20 8 irq7 23 9 irq8 26 10 irq9 29 11 irq10 32 12 irq11 35 13 irq12 38 14 irq13 41 15 irq14 44 16 irq15 47 the ser_irq data frame supports irq2 from a logical device on period 3, which can be used for the system management interrupt (nsmi). when using period 3 for irq2 the user should mask off the smi via the smi enable register. likewise, when using period 3 for nsmi the user should not configure any logical devices as using irq2. ser_irq period 14 is used to transfer irq13. logical device s 0 (fdc), 3 (par port), 4 (ser port 1), 5 (ser port 2), and 7 (kbd) shall have irq13 as a choice for their primary interrupt. the smi is enabled onto the smi frame of the serial irq vi a bit 6 of smi enable register 2 and onto the nio_smi pin via bit 7 of the smi enable register 2. stop cycle control once all irq/data frames have completed the host controll er will terminate ser_irq activity by initiating a stop frame. only the host controller can initiate the stop frame. a stop frame is indicated when the ser_irq is low for two or three clocks. if the stop frame?s low time is two clocks then the next ser_irq cycle?s sampled mode is the quiet mode; and any ser_irq device may initiate a st art frame in the second clock or more after the rising edge of the stop frame?s pulse. if the st op frame?s low time is three clocks then the next ser_irq cycle?s sampled mode is the continuos mode; and only the host controller may initiate a start frame in the second clock or more after the rising edge of the stop frame?s pulse. latency latency for irq/data updates over the ser_irq bus in bridge-less systems with the minimum host supported irq/data frames of seventeen, will range up to 96 clocks (3.84us with a 25mhz pci bus or 2.88us with a 33mhz pci bus). if one or more pci to pci bridge is added to a system, the latency for irq/data updates from the secondary or tertiary buses will be a few clocks longer for synchronous buses, and approximately double for asynchronous buses. eoi/isr read latency any serialized irq scheme has a potential implementation issue related to irq latency. irq latency could cause an eoi or isr read to precede an irq transit ion that it should have followed. this could cause a system fault. the host interrupt controller is responsible for ensuring that these latenc y issues are mitigated. the recommended solution is to delay eois and isr reads to the interrupt controller by the same amount as the ser _irq cycle latency in order to ensure that these events do not occur out of order. ac/dc specification issue all ser_irq agents must drive / sample ser_irq synchrono usly related to the rising edge of pci bus clock. the ser_irq pin uses the electrical specif ication of pci bus. electrical parameters will follow pci spec. section 4, sustained tri-state.
smsc ds ? LPC47M15X page 104 rev. 08/02/2001 reset and initialization the ser_irq bus uses npci_reset as its reset signal. the ser_irq pin is tri-stated by all agents while npci_reset is active. with reset, ser_irq slaves are put in to the (continuous) idle mode. the host controller is responsible for starting the initial ser_irq cycle to co llect system?s irq/data default values. the system then follows with the continuous/quiet mode protocol (stop fr ame pulse width) for subsequent ser_irq cycles. it is host controller?s responsibility to pr ovide the default values to 8259?s and other system logic before the first ser_irq cycle is performed. for ser_i rq system suspend, insertion, or remo val application, the host controller should be programmed into continuous (idle) mode first. this is to guarantee ser_irq bus is in idle state before the system configuration changes. 6.11 8042 keyboard cont roller description the LPC47M15X is a super i/o and universal keyboard cont roller that is designed for intelligent keyboard manage- ment in desktop computer applications. the universal ke yboard controller uses an 8042 microcontroller cpu core. this section concentrates on the lpc4 7m15x enhancements to the 8042. fo r general information about the 8042, refer to the ?hardware description of the 8042 ? in the 8-bit embedded controller handbook. 8042a p27 p10 p26 tst0 p23 tst1 p22 p11 kdat kclk mclk mdat keyboard and mouse interface ls05 kirq is the keyboard irq mirq is the mouse irq port 21 is used to create a gat ea20 signal from the LPC47M15X. 6.11.1 keyboard interface the LPC47M15X lpc interface is functionally compatible with the 8042 style host interface. it consists of the d0-7 data signals; the read and write signals an d the status register, input data register, and output data register. table 49 shows how the interface decodes the control signals. in addition to the above signals, the host interface includes keyboard and mouse irqs. table 49 ? i/o address map address command block function (note 1) 0x60 write kdata keyboard data write (c/d=0) read kdata keyboard data read 0x64 write kdctl keyboard command write (c/d=1) read kdctl keyboard status read note 1: these registers consist of three separate 8 bit regi sters. status, data/command write and data read.
smsc ds ? LPC47M15X page 105 rev. 08/02/2001 keyboard data write this is an 8 bit write only register. when written, the c/d status bit of the status register is cleared to zero and the ibf bit is set. keyboard data read this is an 8 bit read only register. if enabled by ?en able flags?, when read, the kirq output is cleared and the obf flag in the status register is cleared. if not enable d, the kirq and/or auxobf1 mu st be cleared in software. keyboard command write this is an 8 bit write only register. when written, the c/d status bit of the status register is set to one and the ibf bit is set. keyboard status read this is an 8 bit read only register. refer to the de scription of the status register for more information. cpu-to-host communication the LPC47M15X cpu can write to the output data register vi a register dbb. a write to this register automatically sets bit 0 (obf) in the stat us register. see table 50. table 50 ? host interface flags 8042 instruction flag out dbb set obf, and, if enabled, the kirq output signal goes high host-to-cpu communication the host system can send both commands and data to the input data register. the cpu differentiates between commands and data by reading the value of bit 3 of the status register. when bi t 3 is ?1?, the cpu interprets the register contents as a command. when bi t 3 is ?0?, the cpu interprets the regi ster contents as data. during a host write operation, bit 3 is set to ?1? if sa2 = 1 or reset to ?0? if sa2 = 0. kirq if ?en flags? has been executed and p24 is set to a one: the obf flag is gated onto kirq. the kirq signal can be connected to system interrupt to signify that the lpc47m 15x cpu has written to the ou tput data register via ?out dbb,a?. if p24 is set to a zero, kirq is forced low. on power-up, after a valid rst pulse has been delivered to the device, kirq is reset to 0. kirq will normally reflects the status of writes ?d bb?. (kirq is normally selected as irq1 for keyboard support.) if ?en flags? has not been executed: kirq can be controlled by writing to p24. writing a zero to p24 forces kirq low; a high forces kirq high. mirq if ?en flags? has been executed and p25 is set to a one:; ibf is inverted and gated onto mirq. the mirq signal can be connected to system interrupt to signify that t he LPC47M15X cpu has read the dbb register. if ?en flags? has not been executed, mirq is controlled by p25, writing a zero to p25 forces mirq low, a high forces mirq high. (mirq is normally selected as irq12 for mouse support). gate a20 a general purpose p21 is used as a software controlled gate a20 or user defined output. 8042 pins the 8042 functions p17, p16 and p12 are implemented as in a true 8042 part. reference the 8042 spec for all timing. a port signal of 0 drives the out put to 0. a port signal of 1 causes the port enable signal to drive the output to 1 within 20-30nsec. after 500nsec (s ix 8042 clocks) the port enable goes aw ay and the external pull-up maintains the output signal as 1. in 8042 mode, the pins can be programmed as open drain. when programmed in open drain mode, the port enables do not come into play. if the port signal is 0 the output will be 0. if the port signal is 1, the output tristates: an extern al pull-up can pull the pin high, and the pin can be shared. in 8042 mode, the pins cannot be programmed as input nor inverted through the gp configuration registers.
smsc ds ? LPC47M15X page 106 rev. 08/02/2001 6.11.2 external keyboard and mouse interface industry-standard pc-at-compatible keyboards employ a two-wi re, bidirectional ttl interface for data transmission. several sources also supply ps/2 mouse products that employ the same type of interface. to facilitate system expansion, the LPC47M15X provides four signal pins that may be used to im plement this interface directly for an external keyboard and mouse. the LPC47M15X has four high-drive, open- drain output, bidirectional port pins that can be used for external serial interfaces, such as external keyboard and ps/2-type mouse interfaces. they are kclk, kdat, mclk, and mdat. p26 is inverted and output as kclk. the kclk pin is c onnected to test0. p27 is inverted and output as kdat. the kdat pin is connected to p10. p23 is inverted and ou tput as mclk. the mclk pin is connected to test1. p22 is inverted and output as mdat. t he mdat pin is connected to p11. note: external pull-ups may be required. 6.11.3 keyboard power management the keyboard provides support for two power-saving modes: soft powerdown mode and hard powerdown mode. in soft powerdown mode, the clock to the alu is stopped but the timer/counter and interrupts are still active. in hard power down mode the clock to the 8042 is stopped. soft power down mode this mode is entered by executing a halt instruction. t he execution of program code is halted until either reset is driven active or a data byte is written to the dbbin regi ster by a master cpu. if this mode is exited using the interrupt, and the ibf interrupt is enabled, then program ex ecution resumes with a call to the interrupt routine, otherwise the next instruction is exec uted. if it is exited using reset then a normal reset sequence is initiated and program execution starts from program memory location 0. hard power down mode this mode is entered by executing a stop instruction. the os cillator is stopped by disabling the oscillator driver cell. when either reset is driven active or a data byte is written to the dbbin register by a master cpu, this mode will be exited (as above). however, as the oscillator ce ll will require an initialization time, either reset must be held active for sufficient time to allow the oscillator to stabilize. program execution will resume as above. 6.11.4 interrupts the LPC47M15X provides the two 8042 interr upts: ibf and the timer/counter overflow. 6.11.5 memory configurations the LPC47M15X provides 2k of on-chip rom and 256 bytes of on-chip ram. 6.11.6 register definitions host i/f data register the input data register and output data register are each 8 bits wide. a write to this 8 bit register will load the keyboard data read buffer, set the obf flag and set the kirq output if enabled. a read of this register will read the data from the keyboard data or command write buffer and clear the ibf flag. refer to t he kirq and status register descriptions for mo re information. host i/f status register the status register is 8 bits wide. table 51 shows the contents of the status register. table 51 ? status register d7 d6 d5 d4 d3 d2 d1 d0 ud ud ud ud c/d ud ibf obf status register this register is cleared on a reset. this register is r ead-only for the host and read/wr ite by the LPC47M15X cpu. ud writable by LPC47M15X cpu. these bits are user-definable.
smsc ds ? LPC47M15X page 107 rev. 08/02/2001 c/d (command data)-this bit specifies whether the input data register contains data or a command (0 = data, 1 = command). during a host data/command write operation, this bit is set to ?1? if sa2 = 1 or reset to ?0? if sa2 = 0. ibf (input buffer full)- this flag is set to 1 whenever the host system writes data into the input data register. setting this flag activates the LPC47M15X cpu?s ni bf (mirq) interrupt if enabled. when the LPC47M15X cpu reads the input data register (dbb), this bit is aut omatically reset and the interrupt is cleared. there is no output pin associated with this internal signal. obf (output buffer full) - this flag is set to whenever the LPC47M15X cpu write to the output data register (dbb). when the host system reads the output dat a register, this bit is automatically reset. 6.11.7 external clock signal the LPC47M15X keyboard controller clock source is a 12 mh z clock generated from a 14. 318 mhz clock. the reset pulse must last for at least 24 16 mhz clock periods. the pulse-width requirement applies to both internally (vcc por) and externally generated reset signals. in powerdown mode, the external clock signal is not loaded by the chip. 6.11.8 default reset conditions the LPC47M15X has one source of hardware reset: an external reset via the npci_reset pin. refer to table 52 for the effect of each type of re set on the internal registers. table 52 ? resets description hardware reset (npci_reset) kclk low kdat low mclk low mdat low host i/f data reg n/a host i/f status reg 00h n/a: not applicable gatea20 and keyboard reset the LPC47M15X provides two options for gatea20 and keyboard reset: 8042 software generated gatea20 and kreset and port 92 fast gatea20 and kreset. port 92 fast gatea20 and keyboard reset port 92 register this port can only be read or written if port 92 has been enabled via bit 2 of the krst_ga20 register (logical device 7, 0xf0) set to 1. this register is used to support the alternate rese t (nalt_rst) and alternate a20 (alt_a20) functions. name port 92 location 92h default value 24h attribute read/write size 8 bits
smsc ds ? LPC47M15X page 108 rev. 08/02/2001 port 92 register bit function 7:6 reserved. returns 00 when read 5 reserved. returns a 1 when read 4 reserved. returns a 0 when read 3 reserved. returns a 0 when read 2 reserved. returns a 1 when read 1 alt_a20 signal control. writing a 0 to this bit causes the alt_a20 signal to be driven low. writing a 1 to this bit causes the alt_a20 signal to be driven high. 0 alternate system reset. this read/write bit provides an alternate system reset function. this function provides an alte rnate means to reset the system cpu to effect a mode switch from protected vi rtual address mode to the real address mode. this provides a faster means of reset than is provided by the keyboard controller. this bit is set to a 0 by a system reset. writing a 1 to this bit will cause the nalt_rst signal to pulse active (low) for a minimum of 1 s after a delay of 500 ns. before another nalt_rst pulse can be generated, this bit must be written back to a 0. ngatea20 8042 p21 alt_a20 system na20m 0 0 0 0 1 1 1 0 1 1 1 1 bit 0 of port 92, which generates the nalt_rst signal, is us ed to reset the cpu under program control. this signal is and?ed together externally with the reset signal (nkbdrst) from the keyboard controller to provide a software means of resetting the cpu. this prov ides a faster means of reset than is provided by the keyboard controller. writing a 1 to bit 0 in the port 92 register causes this signal to pulse low for a minimum of 6s, after a delay of a minimum of 14s. before another nalt_rst pulse can be g enerated, bit 0 must be set to 0 either by a system reset of a write to port 92. upon reset, this signal is driven inac tive high (bit 0 in the port 92 register is set to 0). if port 92 is enabled, i.e., bit 2 of krst_ga 20 is set to 1, then a pulse is generated by writing a 1 to bit 0 of the port 92 register and this pulse is and?ed with the pulse gene rated from the 8042. this pul se is output on pin kreset and its polarity is controlled by the gpi/o polarity configuration.
smsc ds ? LPC47M15X page 109 rev. 08/02/2001 8042 p92 pulse gen kbdrs krst_ga2 bit 2 bit 0 p20 krst nalt rst 6us 14us ~ ~ 6us 14us ~ ~ note: when port 92 is writes are ignored and return undefined bit 1 of port 92, the alt_a20 signal, is used to force na 20m to the cpu low for support of real mode compatible software. this signal is externally or?ed with the a 20gate signal from the keyboard controller and cpurst to control the na20m input of the cpu. writing a 0 to bit 1 of the port 92 register forces alt_a20 low. alt_a20 low drives na20m to the cpu low, if a20gate from the keyboard contro ller is also low. writing a 1 to bit 1 of the port 92 register forces alt_a20 high. alt_a20 high drives na20 m to the cpu high, regardle ss of the stat e of a20gate from the keyboard controller. upon reset, this signal is driven low.
smsc ds ? LPC47M15X page 110 rev. 08/02/2001 latches on keyboard and mouse irqs the implementation of the latches on the ke yboard and mouse interrupts is shown below. 8042 vcc dq kint kint new rd 60 clr klatch bit figure 5 ? keyboard latch 8042 vcc dq mint mint new rd 60 clr mlatch bit figure 6 ? mouse latch
smsc ds ? LPC47M15X page 111 rev. 08/02/2001 the klatch and mlatch bits are located in the krst _ga20 register, in logical device 7 at 0xf0. these bits are defined as follows: bit[4]: mlatch ? mouse interrupt latch control bit. 0=mint is the 8042 mint anded with latched mint (default), 1= mint is the latched 8042 mint. bit[3]: klatch ? keyboard interrupt latch cont rol bit. 0=kint is the 8042 kint anded with latched kint (default), 1=kint is the latched 8042 kint. see the ?configuration? section fo r a description of this register. 6.11.9 keyboard and mouse pme generation the LPC47M15X sets the associated pme status bits when the following conditions occur: keyboard interrupt ? mouse interrupt ? active edge on keyboard data signal (kdat) ? active edge on mouse data signal (mdat) these events can cause a pme to be gen erated if the associated pme wake enable register bit and the global pme_en bit are set. refer to the pme support section for mo re details on the pme interface logic and refer to the ?runtime registers? section for details on the pme status and enable registers. the keyboard interrupt and mouse interrupt pmes can be generated when the part is powered by vcc. the keyboard data and mouse data pmes can be generated both when the part is powered by vcc, and when the part is powered by vtr (vcc=0). when using the keyboard and mouse data signals for wakeup, it may be necessary to isolate the keyboard signals (kclk, kdat, mclk, mdat) from the 8042 prior to entering ce rtain system sleep states. th is is due to the fact that the normal operation of the 8042 can prev ent the system from entering a sleep state or trigger false pme events. the LPC47M15X has ?isolation? bits for the keyboard an d mouse signals, which allow the keyboard and mouse data signals to go into the wakeup logic but block the clock and data signals from the 8042. these bits may be used anytime it is necessary to isolate the 8042 keyboard and m ouse signals from the 8042 before entering a system sleep state. see the smsc application note titled ?using the enhanc ed keyboard and mouse wakeup feature in smsc super i/o parts? for more information. the bits used to isolate the keyboard and mouse signals fr om the 8042 are located in logical device 7, register 0xf0 (krst_ga20) and are defined below. these bits reset on vtr por only: bit[6] m_iso. enables/disables isolation of mouse sign als into 8042. does not affect the mdat signal to the mouse wakeup (pme) logic. 1=block mouse clock and data signals into 8042 0= do not block mouse clock and data signals into 8042 bit[5] k_iso. enables/disables isolation of keyboard signals into 8042. does not affect the kdat signal to the keyboard wakeup (pme) logic. 1=block keyboard clock and data signals into 8042 0= do not block keyboard clock and data signals into 8042 when the keyboard and/or mous e isolation bits are used, it may be necessary to reset the 8042 upon exiting the sleep state. if either of t he isolation bits is set prior to entering a sle ep state where vcc goes inactive (s3-s5), then the 8042 must be reset upon exiting the sleep mode. write 0x40 to global configuration register 0x2c to reset the 8042. the 8042 must then be tak en out of reset by writing 0x00 to register 0x2c since the bit that resets the 8042 is not self-clearing. caution: bit 6 of c onfiguration register 0x2c is used to put the 8042 into reset - do not set any of the other bits in register 0x2c, as this may produce undesired results. it is not necessary to reset the 8042 if the isolation bits are used for a sleep state where vcc does not go inactive (s1, s2). user note regarding external keyboard and mouse: this is an application matter resulting from the be havior of the external 8042 in the keyboard. when the external keyboard and external mouse are power ed up, the kdat and mdat lines are driven low. this sets the kbd bit (d3) and the mouse bit (d4) of the pme wa ke status register since the kdat and mdat signals cannot be isolated internal to the part. this causes an io _pme# to be generated if t he keyboard and/or mouse pme events are enabled. note that the keyboar d and mouse isolation bits only prevent the internal 8042 in the part from setting these status bits.
smsc ds ? LPC47M15X page 112 rev. 08/02/2001 case 1: keyboard and/or mouse powered by vtr the kbd and/or mouse status bits will be set upon a vtr por if the keyboard an d/or mouse are powered by vtr. in this case, an io_pme# will not be generated, since the keyboard and mouse pme enable bits are reset to zero on a vtr por. the bios software needs to cl ear these pme status bits after power-up. case 2: keyboard and/or mouse powered by vcc the kbd and/or mouse status bits will be set upon a vcc po r if the keyboard and/or m ouse are powered by vcc. in this case, an io_pme# will be generated if the enable bits were set for wakeup, since the keyboard and mouse pme enable bits are vtr powered. ther efore, if the keyboard and mouse are po wered by vcc, the enable bits for keyboard and mouse events should be cleared prior to entering a sleep state where vcc is removed (i.e., s3) to prevent a false pme from being generated. in this ca se, the keyboard and mouse should only be used as pme and/or wake events from the s0 and/or s1 states. the bios software needs to clear these pme status bits after power-up. 6.12 general purpose i/o the LPC47M15X provides a set of flex ible input/output control functions to the system designer through the 37 independently programmable general purpose i/o pins (gpio) . the gpio pins can perform basic i/o and many of them can be individually enabled to generate an smi and a pme. 6.12.1 gpio pins the following pins include gpio functionality. these pins are defined in the table below. all gpios default to the gpio function except for gp34 and gp35 which default to irrx2 and irtx2. gpio pin gpio register pin# pin name (default func/ alternate funcs) pwr well pci reset vcc por vtr por reg off set (hex) reg pci reset vcc por vtr por soft reset smi/pme notes 32 gp10/j1b1 vcc - - in 23 gp10 - - 0x01 - pme 1 33 gp11/j1b2 vcc - - in 24 gp11 - - 0x01 - pme 1 34 gp12 /j2b1 vcc - - in 25 gp12 - - 0x01 - pme 1 35 gp13 /j2b2 vcc - - in 26 gp13 - - 0x01 - pme 1 36 gp14 /j1x vcc - - in 27 gp14 - - 0x01 - pme 1 37 gp15 /j1y vcc - - in 28 gp15 - - 0x01 - pme 1 38 gp16 /j2x vcc - - in 29 gp16 - - 0x01 - pme 1 39 gp17 /j2y vcc - - in 2a gp17 - - 0x01 - pme 1 41 gp20/p17 vcc - - in 2b gp20 - - 0x01 - smi/pme 1 42 gp21/p16/nds1 vcc - - in 2c gp21 - - 0x01 - smi/pme 1 43 gp22/p12/nmtr1 vcc - - in 2d gp22 - - 0x01 - smi/pme 1 45 gp24/sysopt vcc - - in 2f gp24 - - 0x01 - smi/pme 1 46 gp25/midi_in vcc - - in 30 gp25 - - 0x01 - smi/pme 1 47 gp26/midi_out vcc - - in 31 gp26 - - 0x01 - smi/pme 1 50 gp27/nio_smi vcc - - in 32 gp27 - - 0x01 - nio_smi/pme 1 51 gp30/fan_tach2 vcc - - in 33 gp30 - - 0x01 - smi/pme 1 52 gp31/fan_tach1 vcc - - in 34 gp31 - - 0x01 - smi/pme 1 54 gp32/fan2 vcc out ? low out? low in 35 gp32 0x00 0x00 0x01 - smi/pme 1, 2 55 gp33/fan1 vcc out ? low out? low in 36 gp33 0x00 0x00 0x01 - smi/pme 1, 2 61 irrx2/gp34 vcc - - in 37 gp34 - - 0x05 - smi 62 irtx2/gp35 vtr out ? low out? low out - low 38 gp35 0x04 0x04 0x04 - - 3, 4 63 gp36/nkbdrst vcc - - in 39 gp36 - - 0x01 - - 64 gp37/a20m vcc - - in 3a gp37 - - 0x01 - - 1 gp40/drvden0 vcc - - in 3b gp40 - - 0x01 - - 2 gp41/drvden1 vcc - - in 3c gp41 - - 0x01 - smi/pme 1 17 gp42/nio_pme vtr - - in 3d gp42 - - 0x01 - smi/nio_pme 28 gp43/ddrc vcc in in in 3e gp43 note 5 note 5 0x01 - smi/pme 1, 5
smsc ds ? LPC47M15X page 113 rev. 08/02/2001 gpio pin gpio register pin# pin name (default func/ alternate funcs) pwr well pci reset vcc por vtr por reg off set (hex) reg pci reset vcc por vtr por soft reset smi/pme notes 92 gp50/nri2 vcc - - in 3f gp50 - - 0x01 - pme 1 94 gp51/ndcd2 vcc - - in 40 gp51 - - 0x01 - pme 1 95 gp52/rxd2(irrx) vcc - - in 41 gp52 - - 0x01 - pme 1 96 gp53/txd2 (irtx) vtr out ? low out? low out? low 42 gp53 0x00 0x00 0x00 - pme 1, 3 97 gp54/ndsr2 vcc - - in 43 gp54 - - 0x01 - smi/pme 1 98 gp55/nrts2 vcc - - in 44 gp55 - - 0x01 - smi/pme 1 99 gp56/ncts2 vcc - - in 45 gp56 - - 0x01 - smi/pme 1 100 gp57/ndtr2 vcc - - in 46 gp57 - - 0x01 - smi/pme 1 48 gp60/led1 vtr - - in 47 gp60 - - 0x01 - smi/pme 1 49 gp61/led2 vtr - - in 48 gp61 - - 0x01 - smi/pme 1 note 1: these pins are inputs to vcc and vtr powered logic. note 2: the fan control pins (fan1 and fan2) come up as outputs and low following a vcc por and hard reset. note 3: the irtx pins (irtx2/gp35 and gp53/txd2(irtx)) are driven low when the part is powered by vtr (vcc=0v with vtr=3.3v). these pins will remain lo w following a vcc por until irtx function is selected by setting the activate bit, at which time the pin will reflec t the state of the transmit out put of the ir block. it will remain low following a vcc por until gpio output f unction is selected, at which time the pin will reflect the state of the gpio data bit. the gp53/txd2 (irtx) pin will remain low following a vcc por (in addition to conditions stated above) until serial port 2 is enabled by setting the activate bit, at which time the pin will reflect the stat e of the transmit output of the serial port 2 block. note 4: these pins are inputs to vcc powered logic. note 5: bits [3:2] (alternate function select bits) of this register are reset (cleared) on vcc por and hard reset (and vtr por). 6.12.2 description each gpio port has a 1-bit data register and an 8-bit conf iguration control register. the data register for each gpio port is represented as a bit in one of the 8-bit gpio data r egisters, gp1 to gp6. the bits in these registers reflect the value of the associated gpio pin as follows. pin is an input: the bit is the value of the gpio pin. pin is an output: the value written to the bit goes to the gpio pin. latched on read and wr ite. all of the gpio registers are located in the pme block see ?run time register? secti on. the gpio ports with their alternate functions and configuration state r egister addresses are listed in table 53. table 53 ? general purpose i/o port assignments qfp pin# default functio n alt. func. 1 alt. func. 2 alt. func. 3 data register 1 data register bit no. register offset (hex) 32 gpio joystick 1 button 1 0 33 gpio joystick 1 button 2 1 34 gpio joystick 2 button 1 2 35 gpio joystick 2 button 2 3 36 gpio joystick 1 x-axis 4 37 gpio joystick 1 y-axis 5 38 gpio joystick 2 x-axis 6 39 gpio joystick 2 y-axis gp1 7 4b 41 gpio p17 0 42 gpio p16 eeti 1 43 gpio p12 eeti 2 n/a reserved 3 45 gpio (system option) 4 46 gpio midi_in gp2 5 4c
smsc ds ? LPC47M15X page 114 rev. 08/02/2001 qfp pin# default functio n alt. func. 1 alt. func. 2 alt. func. 3 data register 1 data register bit no. register offset (hex) 47 gpio midi_out 6 50 gpio smi output 7 51 gpio fan tachometer 2 0 52 gpio fan tachometer 1 1 54 gpio fan speed control 2 2 55 gpio fan speed control 1 3 61 infrared rx gpio 4 62 infrared tx gpio 5 63 gpio keyboard reset 6 64 gpio gate a20 gp3 7 4d 1 gpio drive density select 0 0 2 gpio drive density select 1 eeti 1 17 gpio power management event 2 28 gpio device disable reg. control eeti 3 n/a reserved gp4 7:4 4e 92 gpio ring indicator 2 0 94 gpio data carrier detect 2 1 95 gpio receive serial data 2 2 96 gpio transmit serial data 2 3 97 gpio data set ready 2 4 98 gpio request to send 2 5 99 gpio clear to send 2 6 100 gpio date terminal ready gp5 7 4f 48 gpio led eeti 0 49 gpio led eeti 1 n/a reserved gp6 7:2 50 note 1: the gpio data and configuratio n registers are located in pme blo ck at the offset shown from the pme_blk address. 6.12.3 gpio control each gpio port has an 8-bit control regi ster that controls the beha vior of the pin. these r egisters are defined in the ?runtime registers? section of this specification. each gpio port may be configured as either an input or an output. if the pin is configured as an output, it can be programmed as open-drain or push-pull. inputs and outputs c an be configured as non-inverting or inverting. bit[0] of each gpio configuration regi ster determines the port direction, bit[1] determines the signal polarity, and bit[7] detemines the output driver type select. the gpio configuration regi ster output type select bit[7] applies to gpio functions and the nsmi alternate functions. the polarity bit (bit 1) of the gpio control registers c ontrol the gpio pin when the pi n is configured for the gpio function and when the pin is configured for the alternate fu nction for all pins, with the exception of the ddrc function on gp43, the analog game port pins (j1x, j1y, j2x, j2 y) and the either edge triggered interrupts. when the alternate function is selected for the analog joystick pi ns (gp14, gp15, gp16 and gp17), these pins become open drain, non-inverted outputs. the basic gpio configuration opti ons are summarized in table 54.
smsc ds ? LPC47M15X page 115 rev. 08/02/2001 table 54 ? gpio configuration summary selected function direction bit polarity bit description b0 b1 0 0 pin is a non-inverted output. 0 1 pin is an inverted output. 1 0 pin is a non-inverted input. gpio 1 1 pin is an inverted input. 6.12.4 gpio operation gpio pin gpio data register bit-n sd-bit gpx_nior gpio configuration register bit-1 (polarity) gpio configuration register bit-0 (input/output) 1 0 d-type transparent gpx_niow dq qd figure 7 ? gpio function illustration the operation of the gpio ports is illustrated in figure 7. note: figure 7 is for illustration purposes only and is not intended to suggest specific implementation details. note: when the following functions are selected, the associ ated gpio pins have bi-directional functionality: p12, p16, p17 and game port x-axis and y-axis inputs (j1x, j1y, j2x, j2y). when a gpio port is programmed as an input, reading it throug h the gpio data register latc hes either the inverted or non-inverted logic value present at the gpio pin. writing to a gpio port t hat is programmed as an input has no effect (table 55) when a gpio port is programmed as an output, the logic value or the inverted logic value t hat has been written into the gpio data register is output to the gpio pin. reading from a gpio port t hat is programmed as an output returns the last value written to the data register (table 55). when the gpio is programmed as an output, the pin is excluded from the pme and smi logic. table 55 ? gpio read/write behavior host operation gpio input port gpio output port read latched value of gpio pin last write to gpio data register write no effect bit placed in gpio data register
smsc ds ? LPC47M15X page 116 rev. 08/02/2001 the LPC47M15X provides 31 gpios that can directly generate a pme. see t he table in the next section. the polarity bit in the gpio control registers select the edge on these gpio pins th at will set the associated status bit in the pme_sts 2 register. the default is the low-to-high edge. if the corresponding enable bit in the pme_en 2 register and the pme_en bit in the pme_en register is se t, a pme will be generated. these registers are located in the pme_blk of runtime registers whic h are located at the address contained in the configuration registers 0x60 and 0x61 in logical device a. the pme status bits for the gpios are cleared on a write of ?1?. in addition, the LPC47M15X provides 19 gpios that can directly generate an smi. see the table in the next section. 6.12.5 gpio pme and smi functionality the following gpios are dedicated wakeup gpios with a status and enable bit in the pme status and enable registers: gp10-gp17 gp20-gp22, gp24-gp27 gp30-gp33 gp41, gp43 gp50-gp57 gp60, gp61 the following pme status and enabl e registers for these gpios: pme_sts2 and pme_en2 for gp10-gp17 pme_sts3 and pme_en3 for gp20-gp22, gp24-gp27 pme_sts4 and pme_en4 for gp30-gp33, gp41, gp43, gp60 and gp61 pme_sts5 and pme_en5 for gp50-gp57 the following gpios can directly generate an smi and have a status and enable bit in the smi status and enable registers: gp20-gp22, gp24-gp26 gp30-gp33 gp41, gp42, gp43 gp54-gp57 gp60, gp61 the following smi status and enable registers for these gpios: smi_sts3 and smi_en3 for gp20-gp22, gp24- gp26 and gp60 smi_sts4 and smi_en4 for gp30-gp33, gp41, gp42, gp43 and gp61 smi_sts5 and smi_en5 for gp54-gp57, fan_tach1 and fan_tach2 the following gpios have ?either edge triggered interrupt? (eeti) input capability. these gpios can generate a pme and an smi on both a high-to-low and a low-to-high edge on the gpio pin. these gpios have a status bit in the msc_sts status register that is set on both edges. the corresponding bits in the pme and smi status registers are also set on both edges: gp21, gp22 gp41, gp43 gp60, gp61 the following table summarizes the pme and smi functionalit y for each gpio. it also shows the either edge triggered interrupt (eeti) input capability for the gpio s and the power source for the buffer on the i/o pads. gpio pme smi eeti buffer power notes gp10-gp17 yes no no vcc 4 gp20-gp22, gp24-gp26 yes yes gp21, gp22 vcc 4 gp27 yes nio_smi no vcc 4 gp30, gp31 yes yes no vcc 4 gp32, gp33 yes yes no vcc 5 gp34 no yes no vcc gp35 no no no vtr 1
smsc ds ? LPC47M15X page 117 rev. 08/02/2001 gpio pme smi eeti buffer power notes gp36, gp37 no no no vcc 2 gp40 no no no vcc 2 gp41 yes yes yes vcc 4 gp42 nio_pme yes no vtr gp43 yes yes yes vcc 4, 6 gp50-gp52 yes no no vcc 4 gp53 yes no no vtr 1, 5 gp54-gp57 yes yes no vcc 4 gp60, gp61 yes yes yes vtr 3, 4 note 1: gp35 and gp53 have the irtx function and their out put buffers are powered by vtr so that the pins are always forced low when not used. note 2: gp36-gp37 and gp40 should not be connected to any vtr powered external circuitry. these pins are not used for wakeup. note 3: gp60 and gp61 have led functionality which must be active under vtr so its buffer is powered by vtr. note 4: these pins can be used for wakeup events to generate a pme while the part is under vtr power (vcc=0). note 5: these pins cannot be used for wakeup events to generate a pme while the part is under vtr power (vcc=0). the gp32, gp33 and gp53 pins co me up as output and low on a vcc por and hard reset. note 6: gp43 defaults to the gpio function on vcc por and hard reset. 6.12.6 either edge triggered interrupts six gpio pins are implemented such that they allow an inte rrupt (pme or smi) to be generated on both a high-to-low and a low-to-high edge transition, instead of one or the other as selected by the polarity bit. the either edge triggered interrupts (eeti) function as follow s: if the eeti function is sele cted for the gpio pin, then the bits that control input/out put, polarity and open drain/push-pull have no effe ct on the function of the pin. however, the polarity bit does affect the value of the gp bit (i.e., register gp2, bit 2 for gp22). a pme or smi interrupt occurs if the pme or smi enable bit is set for the corresponding gpio and the eeti function is selected on the gpio. the pme or smi status bits are set when the eeti pin transitions (on either edge) and are cleared on a write of ?1?. there are also status bits for the eetis located in the msc_sts register, which are also cleared on a write of ?1?. the msc_sts register provides t he status of all of the eeti interrupts within one register. the pme, smi or msc status is valid whether or not the interrupt is enabled and whether or not the eeti function is selected for the pin. miscellaneous status register (msc_sts) is for the either edge triggered interru pt status bits. if the eeti function is selected for a gpio then both a high-to-low and a low-to -high edge will set the corresponding msc status bits. status bits are cleared on a write of ?1?. see the ?runtime registers? section for more information. the configuration register for the eit her edge triggered interrupt status bits is defined in the ?runtime registers? section. 6.12.7 led functionality the LPC47M15X provides led function ality on two gpios, gp60 and gp61. thes e pins can be configured to turn the led on and off and blink independent of each other through the led1 and led2 runtime registers at offset 0x5d and 0x5e from the base address located in the pr imary base i/o address in logical device a. the led pins (gp60 and gp61) are able to control the led while the part is under vtr power with vcc removed. in order to control a led while the part is under vtr powe r, the gpio pin must be c onfigured for the led function and either open drain or push-pull buffer type. in the case of open-drain buffer type, the pin is capable of sinking current to control the led. in the case of push-pull buffe r type, the part will source current. the part is also able to blink the led under vtr power. the led will not blink u nder vtr power (vcc removed) if the external 32khz clock is not connected. the led pins can drive a led when the buffer type is configured to be push-pull and the part is powered by either vcc or vtr, since the buffers for these pins are powered by vtr. this means they will source their specified current from vtr even when vcc is present.
smsc ds ? LPC47M15X page 118 rev. 08/02/2001 the led control registers are defined in the ?runtime register? section. 6.13 system management interrupt (smi) the LPC47M15X implements a ?group? ni o_smi output pin. the system m anagement interrupt is a non-maskable interrupt with the highest priority level used for os trans parent power management. the nsmi group interrupt output consists of the enabled interrupts from each of the functional blocks in the chip and many of the gpios and the fan tachometer pins. the gp27/nio_smi pin, when selected for the nio_smi function, can be programmed to be active high or active low via the polarity bit in the gp27 regist er. the output buffer type of t he pin can be programmed to be open-drain or push-pull via bit 7 of the gp27 register. th e nio_smi pin function defaults to active low, open-drain output. the interrupts are enabled onto the gro up nsmi output via the smi enable regist ers 1 to 5. the nsmi output is then enabled onto the group nio_smi output pin via bit[7] in th e smi enable register 2. the smi output can also be enabled onto the serial irq stream (irq2) via bit[6] in t he smi enable register 2. the internal smi can also be enabled onto the nio_pme pin. bit[5] of the smi enable register 2 is used to enab le the smi output onto the nio_pme pin (gp42). this bit will enable the internal sm i output into the pme logic through the devint_sts bit in pme_sts3. see pme section for more details. an example logic equation for the nsmi output for smi registers 1 and 2 is as follows: nsmi = (en_pint and irq_pint) or (en_u2int and irq_u2 int) or (en_u1int and irq_u1int) or (en_fint and irq_fint) or (en_mpu401 and irq_mpu401) or (en_mi nt and irq_mint) or (en_kint and irq_kint) or (en_irint and irq_irint) or enp12 and irq_p12) note: the prefixes en and irq are used above to indicate smi enable bit and smi status bit respectively. 6.13.1 smi registers the smi event bits for the gpios and the fan tachometer ev ents are located in the smi status and enable registers 3-5. the polarity of the edge used to set the status bit and generate an smi is controlled by the polarity bit of the control registers. for non-inverted polari ty (default) the status bit is set on the low-to-high edge. if the eeti function is selected for a gpio then both a high-to-low and a low-to -high edge will set the corresponding smi status bit. status bits for the gpios ar e cleared on a write of ?1?. the smi logic for these events is implemented such that the ou tput of the status bit for each event is combined with the corresponding enable bit in order to generate an smi. the smi registers are accessed at an o ffset from pme_blk (see ?runtime regist ers? section for more information). the smi event bits for the super i/o devices are located in the smi status and enable regi ster 1 and 2. all of these status bits are cleared at the source except for irint, wh ich is cleared by a read of the smi_sts2 register; these status bits are not cleared by a write of ?1?. the smi logic for these events is implemented such that each event is directly combined with the corresponding enable bit in order to generate an smi. see the ?runtime registers? section fo r the definition of these registers.
smsc ds ? LPC47M15X page 119 rev. 08/02/2001 6.14 pme support the LPC47M15X offers support for power management events (p mes), also referred to as a system control interrupt (sci) events in an acpi system. a power management event is indicated to the chipset via the assertion of the nio_pme signal. in the LPC47M15X, the nio_pme is asserted by active transitions on the ring indicator inputs nri1 and nri2, valid nec infrared remote control frames, ac tive keyboard-data edges, active mouse-data edges, programmable edges on gpio pins and fan tachometer event. the gp42/nio_pme pin, when selected for the nio_pme function, can be programmed to be active high or ac tive low via the polarity bit in the gp42 register. the output buffer type of the pin can be programmed to be open- drain or push-pull via bit 7 of the gp42 register. the nio_pme pin function defaults to active low, open-drain output. note: if the nri2 pin is used for wa keup, the inactive state of the txd2 pin may need to be changed. see the ir transmit pin section. the pme functionality is controlled by the pme status and enable registers in the runtime registers block, which is located at the address programmed in configuration registers 0x60 and 0x61 in logical device a. the pme enable bit, pme_en, globally controls pme wake-up events. w hen pme_en is inactive, the nio_pme signal can not be asserted. when pme_en is asserted, any wake source whos e individual pme wake enable register bit is asserted can cause nio_pme to become asserted. the pme status register indicates that an enabled wake source has occurred, and if the pme_en bit is set, asserted the nio_pme signal. the pme status bit is asserted by active transitions of pme wake sources. pme_status will become asserted independent of the state of the global pme enable bit, pme_en. the following pertains to the pme status bits for each event: the output of the status bit for eac h event is combined with the corresponding enable bit to set the pme status bit. the status bit for any pending events must be cleared in order to clear the pme_sts bit. status bits are cleared on a write of ?1?. for the gpio events, the polarity of the edge used to set the status bit and generate a pme is controlled by the polairty bit of the gpio control register . for non-inverted polarity (default) t he status bit is set on the low-to-high edge. if the eeti function is select ed for a gpio then both a high-to-low and a low-to-high edge will set the corresponding pme status bits. status bits are cleared on a write of ?1?. the pme wake registers also include status and enable bits for the fan tachometer input. see the ?keyboard and mouse pme generation? section for information about using the keyboard and mouse signals to generate a pme. in the LPC47M15X the nio_pme pin can be programmed to be an open drain, active low, driver. the LPC47M15X nio_pme pin is fully isolated from other external devices that might pull the nio_pme si gnal low; i.e., the nio_pme signal is capable of being driven high externally by a nother active device or pullup even when the LPC47M15X vcc is grounded, providing vtr power is active. the lpc47m 15x nio_pme driver sinks 6m a at .55v max (see section 4.2.1.1 dc specifications , page 122, in the ?pci local bu s specification,? revision 2.1). the pme registers are run-time registers as follows. thes e registers are located in s ystem i/o space at an offset from pme_blk, the address programmed in logi cal device a at registers 0x60 and 0x61. the following registers are for gpio wakeup events: pme wake status 2 (pme_sts2), pme wake enable 2 (pme_en2) pme wake status 3 (pme_sts3), pme wake enable 3 (pme_en3) pme wake status 4 (pme_sts4), pme wake enable 4 (pme_en4) pme wake status 5 (pme_sts5), pme wake enable 5 (pme_en5) see pme register description in t he ?runtime registers? section.
smsc ds ? LPC47M15X page 120 rev. 08/02/2001 enabling smi events onto the pme pin there is a bit in the pme status register 3 to show the status of the internal ?group? smi signal in the pme logic (if bit 5 of the smi_en2 register is set). this bit, devint_sts, is at bit 3 of the pme_sts3 regi ster. this bit is defined as follows: 0=the group smi output is inactive. 1 = the group smi output is active. note: bit 5 of the smi_en2 register must also be set. this bit is cleared on a write of ?1?. there is a bit in the pme enable register 3 to enable the smi onto the nio_pme pin (if the nio_pme function is selected for gp42). this bit, devint_en, is at bit 3 of the pm e_en3 register. this bit will enable the internal ?group? smi signal (if bit 5 of the smi_en2 register is set) into the pme logic through the devint_sts bit as follows: if the devint_en bit is ?1? and the devint_sts bit is ?1? then t he nio_pme pin will be active. this pin has its polarity controlled by the polarity bit in the gp42 register. this bit is defined as follows: 0 = disable group smi output from the nio_pme pin. 1 = enable group smi output onto the nio_ pme pin. that is, if this bit is set and the devint_sts bit is set then a npme is generated. note: bit 5 of the smi_en2 register must also be set. 6.14.1 ?wake on specific key? option the LPC47M15X has logic to detect a single keyboard sc an code for wakeup (pme generation). the scan code is programmed onto the keyboard scan code register, a runtime register at offset 0x5f from the base address located in the primary base i/o address in logical device a. this register is powered by vtr and reset on vtr por. the pme status bit for this event is located in the pme_sts1 register at bit 5 and the pme enable bit for this event is located in the pme_en1 register at bi t 5. see the ?runtime registers? secti on for a definition of these registers. data transmissions from the keyboard consist of an 11-bit serial data stream. a logic 1 is sent at an active high level. the following table shows the functions of the bits. bit function 1 start bit (always 0) 2 data bit 0 (least significant bit) 3 data bit 1 4 data bit 2 5 data bit 3 6 data bit 4 7 data bit 5 8 data bit 6 9 data bit 7 (most significant bit) 10 parity bit (odd parity) 11 stop bit (always 1) the timing for the keyboard clock and data signals are shown in the ?timing diagrams? section. the process to find a match for the scan code stored in the keyboard scan code register is as follows: 1) begin sampling the data at the first falling edge of th e keyboard clock following a period where the clock line has been high for 115-145usec. the data at this first clock edge is the start bit. the first data bit follows the start bit (clock 2). sample the data on each falling edge of the clock. store the eight bits following the stop bit to compare with the scan code stored in the keyboard scan c ode register. sample the comparator within 100usec of the falling edge of clock 9 (for example, at clock 10). 2) sample the parity bit and check that the 8 data bits plus the parity bit always have an odd number of 1?s (odd parity) . 3) repeat until a match is found. if t he 8 data bits match the scan code stored in the keyboard scan code register and the parity is correct, then it is c onsidered a match. when a match is f ound and if the stop bit is 1, set the event status bit (bit 5 of the pme_ sts1 register) to ?1? within 100usec of the falling edge of clock 10.
smsc ds ? LPC47M15X page 121 rev. 08/02/2001 4) the state machine will reset after 11 clocks and the proce ss will restart. the process will continue until it is shut off by setting the spekey_en bit (see following sub-section). 5) the state machine will reset if there is a period where the clock remains high for more than one keyboard clock period (115-145usec) in the middle of the transmission (i.e., before clock 11). this is to prevent the generation of a false pme. 6) the spekey_en bit at bit 1 of the cloc ki32 register at 0xf0 in logical de vice a is used to control the ?wake- on-specific feature. th is bit is used to turn the logic for this feat ure on and off. it will disable the 32khz clock input to the logic. the logic will draw no power when disabled. the bit is defined as follows: 0= ?wake on specific key? logic is on (default) 1= ?wake on specific key? logic is off note: the generation of a pme for this event is controlled by the pme enable bit (located in the pme_en1 register at bit 5) when the logic for feature is turned on. 6.15 fan speed cont rol and monitoring the LPC47M15X can control the speed of two separate fans as well as monitor them if they are equipped with fan tachometer outputs. the following secti ons will clarify how this chip controls the speed of a fan and its? monitoring capabilities. 6.15.1 fan speed control the fan speed control for the LPC47M15X is implemented as pulse width modulators with fan clock speed selection. there are two pins, fan1 and fan2 (pins 55 and 54 respecti vely), that can controll the speed of two separate fans. these signals are controlled by the ru ntime registers fanx and fan control th at are described below (also see the ?runtime registers? section). note: these fan control pins come up as outputs and are low following a vcc por and hard reset. these pins may not be used for wakeup events under vtr power (vcc=0). fan speed control summary the following table illustrates t he different modes for the fans. table 56 ? different modes for fan fanx clock control bit (note 1) fanx clock multiplier bit (note 2) fanx clock source select bit (note 3) fanx clock select bit (note 4) f out 6-bit duty cycle control bits[6:1] (dcc) duty cycle (%) 0 x x x 0hz ? low 0 - 0 0 0 0 15.625khz 1-63 (dcc/64) 0 0 0 1 23.438khz x 100 0 0 1 0 40hz 0 0 1 1 60hz 0 1 0 0 31.25khz 0 1 0 1 46.876khz 0 1 1 0 80hz 0 1 1 1 120hz 1 x x x 0hz ? high - - note 1: this is fanx register bit 0 note 2: this is fan control register bit 2 or 3 note 3: this is fan control register bit 0 or 1 note 4: this is fanx register bit 7
smsc ds ? LPC47M15X page 122 rev. 08/02/2001 fanx registers the fan1 and fan2 registers are located at 0x56 and 0x57 fr om base i/o in logical device a. the bits are defined below. see the register description in the ?runtime registers? section. fan x clock select bit, d7 the fan x clock select bit in the fanx registers is used with the fan x clock source select and the fan x clock multiplier bits in the fan cont rol register to determine the fan speed f out . see table 56 above. duty cycle control for fan x, bits d6 ? d1 the duty cycle control (dcc) bits determine the fan duty cycle. the LPC47M15X has 1.56% duty cycle resolution. when dcc = ?000000? (min. value), f out is always low. when dcc is ?111111? (max. value), f out is almost always high; i.e., high for 63/64 th and low for 1/64 th of the f out period. generally, the f out duty cycle (%) is (dcc/64) x 100. fan x clock control, bit d0 the fan x clock control bit d0 is used to override the duty cycle control for fan x bits and force f out always high. when d0 = ?0?, the dcc bits determine the f out duty cycle. when d0 = 1, f out is always high, regardless of the state of the dcc bits. fan control register the fan control register is located at 0x58 from base i/o in logical device a. the bits are defined below. see the register description in the ?runtime registers? section. fan x count divisor, bits d7-d6 / d5-d4 fan x count divisor bit in fan control register is used to determine fan tachometer count. the choices for the divisor are 1, 2, 4 and 8. s ee ?fan tachometer input? section. fan x clock multiplier, bits d3 / d2 the fan x clock multiplier bit is used with the fan x clock source select bit in the fan control register and the fan x clock select bit in fan register to determine the f out . when the fan x clock multiplier bit = ?0?, no clock multiplier is used. when the fan x clock multip lier bit = ?1?, the clock speed determined by the fan x clock source select bit is doubled. fan x clock source select, bits d1 / d0 the fan x clock source select and the fan x clock multip lier bits in the fan control register is used with the fan x clock select bit in the fan x registers to determine the fan speed f out . see table 56 above. 6.15.2 fan speed monitoring the LPC47M15X monitors the speed of t he fans by utilizing fan tachometer input signals from fans equipped with tachometer outputs. there are two pins that can be conf igured as the fan tachometer inputs (pins 51 and 52) which are monitored by using the fan tachomet er registers. these signals, as well as the fan tachomet er registers, are described below (also see the ?runtime registers? section). fan tachometer inputs a fan tachometer input is used to meas ure the speed at which a fan is rotating. the fan tachometer input is a train of square pulses with a 50% duty cycle (see figure 8) that are derived from the magnetic fields generated by the rotating rotor of the fan. the speed of the fan can be determined by calculat ing the period of the fan tachometer input pulse. note: all calculations are based on fans that emit 2 square pulses per revolution. fan tachometer input clock source for counter t p t r = revolution time = 60/rpm (sec) t p = pulse time = t r /2 (two pulses per revolution) f = 32.786khz / divisor t r figure 8 ? fan tachometer input and clock source
smsc ds ? LPC47M15X page 123 rev. 08/02/2001 the counter is used to determine the peri od of the fan tachometer input pulse. this counter, if reset on the rising edge of the fan tachometer input pulse, measures the num ber of clock pulses generated by the clock source for the duration of one fan tachometer input pulse. since two fan tachometer input pulses are generated per revolution of the fan rotor, the speed of the fan is easily calculated. ev erytime the fan tachometer input resets the counter, it also latches the value of the counter into the fan tachometer r egister. this value is used by the operating system to monitor the speed of the fan. fan monitoring logic the clock source for the counter is t he output of the programm able divider whose input is the 32.768khz oscillator (see figure below). the counter is reset by the rising edge of each fan tachometer input pulse, by itself if it reaches its? maximum count of 0xff, or by writing to the preload register. if the fan is functioning, a value is preloaded into the co unter on the rising edge of the fan tachometer input. the counter counts the number of clock puls es generated for the duration of one fan tachometer input pulse. this value ( count ) is then stored into the fan tachometer register. if the fan is operating at 70% (or less) of the maximum capacity, the count value will be greater than or equal to 192 and thereby generate a pme# signal. to ensure the fan tachometer register has been updat ed if the fan suddenly seizes, a second pme is generated when the counter reaches 0xff and the fan tachometer register is latched again . the fan tachometer register will remain at this value until another fan tachometer input pulse is received. a representation of the logic for the fan ta chometer implementation is shown below. note : if the fan is working the fan tachometer register will be latched by the fan tachometer input. if the fan fails, the first time the overflow bit is generated the fan tachometer register will be updated. the fan tachometer register will not be updated again until after the fan tachometer input resets the counter. preload logic to generate pme event programmable divider 1, 2, 4, 8 counter 32khz latch fan tach register on fan tach input pulse or counter=0xff figure 9 ? conceptual block diagram of fan monitoring logic fan tachometer register the fan tachometer registers are used to store the value of the counter that monitors the speed of the associated fan. this value may be used by the operating sy stem to monitor how the fan is functioning. the acpi bios polls this register perio dically to determine the speed at which the fan rotor is revolving. see the metalious acpi/manageability specification , v1.0, dated april 30, 1999. the bios looks for particular values in this register to determine the rate at whic h the fan is functioning. (i.e. count = ffh; means the fan has stopped). since the count value must correspond to a particular rate of functioning, the preload regist er is used to offset any differences. therefore, the equat ion below has been derived to calculate the desired values for count. the fan count is determined according to the following equation: 1 1.966 x 10 6 count = 2 x rpm x divisor + preload (equation 1) (term 1)
smsc ds ? LPC47M15X page 124 rev. 08/02/2001 in addition to the acpi bios polling t he register, a pme or smi is generated at a count of 192, if enabled through the pme or smi enable register, which corresponds to the ?upp er limit? for the fan count. this value is made to correspond to the ?lower limit? of the rpm for the fan by programming the divisor and preload value accordingly. typical practice is to consider 70% of normal rpm a fan failure. fan preload register the preload value is programmable via the fan1 preload r egister and fan2 preload register. the preload is the initial value for the fan count, which is used to adjust the c ount such that the value of 192 corresponds to the ?lower limit? of the rpm. by setting the preload value and diviso r properly, a pme or smi will be generated when the rpm reaches the percentage of the nominal rpm that indicates a fan failure. notice in the examples shown below the preload value was determined to be 32 for a fan that normally operates at 4400 rpms. this preload value was determined for the case that a pme should be in itiated at 70% of normal operation. a pme is generated when t he counter reaches 192, but at 70% in this example only 160 counts are generated during one fan tachometer input pulse leaving a difference of 32. examples term 1 in the equation above is ? of the value determine d by multiplying the clock source of 32.768khz by 60sec/min and dividing by the product of the revolutions per minute times the divisor. the factor of ? in term 1 corresponds to two pulses per revolution. the default divisor, located in the fan control register, is two. this results in a value for term 1 in equation 1 of 111.70 (~112) for a 4400 rpm. the following tables show examples of the desired functionality. note: all calculations of count were based on tachometer inputs with two pulses per revolution and on the clock source input divided down by two (default settings). rpm time per revolution term 1 for ?divide by 2? (default) in decimal preload count = (term 1) + preload comments 4400 13.64 ms 112 counts 32 144 typical rpm 3080 19.48 ms 160 counts 32 192 70% rpm 2640 22.73 ms 186 counts 32 218 60% rpm 2204 27.22 ms 223 counts 32 255 (maximum count) 50% rpm the divisor for each fan is programmable via the fan control register, logical device a, runtime register 0x58. the choices for the divisor are 1, 2, 4 and 8. the default value is 2. mode select nominal rpm time per revolution preload counts for the given speed in decimal 70% rpm time per revolution for 70% rpm divide by 1 8800 6.82 ms 32 144 6160 9.74 ms divide by 2 4400 13.64 ms 32 144 3080 19.48 ms divide by 4 2200 27.27 ms 32 144 1540 38.96 ms divide by 8 1100 54.54 ms 32 144 770 77.92 ms 6.16 security feature the following register describes the functionalit y to support security in the LPC47M15X. 6.16.1 gpio device disable register control the gpio pin gp43 is used for the device disable register control (ddrc) function. setting bits[3:2] of the gp43 configuration register to ?01?, sele cts the ddrc function for the gp43 pin. when bits[3:2]=01 the gp43 pin is an input, with non-inverted polarity. bits[3:2] cannot be cleared by writing to these bits; they are cleared by vtr por, vcc por and hard reset. that is, when the ddrc function is selected for this pin, it cannot be changed, except by a vcc por, hard reset or vtr por. when the ddrc function is selected for gp43, the device di sable register is controlled by the value of the gp43 pin as follows:
smsc ds ? LPC47M15X page 125 rev. 08/02/2001 ? if the gp43 pin is high, the device disable register is read-only. ? if the gp43 pin is low, the device disable register is read/write. 6.16.2 device disable register the device disable register is located in the pme regist er block at offset 0x22 from the pme_blk base i/o address in logical device a. writes to this register are block ed when the gp43 pin is configured for the device disable register control function (gp 43 configuration register bit 2 =1) and the gp43 pin is high. the configuration register for the device disable regist er is defined in the ?runt ime registers? section. 6.17 game port logic the LPC47M15X implements logic to support a dual game port. this logic includes the following for each game port: two 555 timers, two game port rc constant inputs (x-axis and y-axis), two game port button inputs and game port interface logic. the implementation of the game port uses a simple a/d conv erter constructed from a 555 timer to digitize the analog value of a potentiometer fo r the x-axis and y-axis of the joystick. the figure below illustrates t he implementation of the game por t logic in the LPC47M15X. game software will write a byte to the game port to reset it, and then poll (read) the port until the x and y-axis rc time constant pins (tima,b) time out (return to zero). the elapsed time indicates the resistance value of the potentiometer and in turn, the position of the joystick. the figure below illustrates the timing of the game port signals. the 556 time rs will reset the outputs (outa,b) to zero and the rc constant (tima,b) pins to zero when the rc constant (tima,b) inputs r each 2/3 of vref as shown. vref is the voltage on pin 44, which is either 5v or 3.3v. see the ?vref pin ? section. joyr joystick 1 button 1 joystick 1 button 2 556 out1a out1b trig1a trig1b x-axis y-axis tim1a tim1b joyw vcc = 5v internal to LPC47M15X joystick 1 d0 d1 d2 d3 d4 d5 d6 d7 556 out2a out2b trig2a trig2b x-axis y-axis tim2a tim2b vcc = 5v joystick 2 joystick 2 button 1 joystick 2 button 2 j1b1 j1b2 j2b1 j2b2 j1x j1y j2x j2y game port register vcc = 5v vcc = 5v vcc = 5v internal to joysticks
smsc ds ? LPC47M15X page 126 rev. 08/02/2001 joyw outa,b joyr vref tima,b 2 3 vref t1 the game port register is defined below. it is a runtime regi ster located at the address programmed into the base i/o address (game_port) in logical device 9. note: register 0x60 is the high byte; 0x61 is the low byte. for example, to set the primary base address to 1234h, write 12h into 0x60, and 34h into 0x61. when the activate bit in logical device 9 is cleared, it prevents the base i/o address for the game port from being decoded.
smsc ds ? LPC47M15X page 127 rev. 08/02/2001 game port register register location: +0h system i/o space default value: 00h on vtr por attribute: read-only size: 8-bits d7 d6 d5 d4 d3 d2 d1 d0 button #2 joystick 2 (j2b2) button #1 joystick 2 (j2b1) button #2 joystick 1 (j1b2) button #1 joystick 1 (j1b1) y-axis joystick 2 (out2b) x-axis joystick 2 (out2a) y-axis joystick 1 (out1b) x-axis joystick 1 (out1a) the game port register is a read-only register. however, wr iting to the game port resets the rc time constant pins (tima,b) to zero. the reset of the time constant pins occur on the ?back? edge of the write signal (when the write signal goes from its active state to its inactive state). the game port read (joyr) will be an io read to the address programmed into the base io address in logical device 9. the game port write (joyw) will be an io write to th e address programmed into the base io address in logical device 9. minimum rise time the fastest rise time on the rc constant pins (min imum rc time constant) for the game port is 20usec. 6.17.1 power control register bit 2 in the power control register (cr22) is the power co ntrol bit for the game port. this bit has the same function as the activate bit for logical device 9 and shadows the activate bit. the activate bit also shadows the power control bit 2. 6.17.2 vref pin the LPC47M15X has a reference voltage pin input on pin 44 of the part. this reference voltage can be connected to either a 5v supply or a 3.3v supply. it is used for the game port. the reference voltage is used in the game port logic so t hat the joystick trigger voltage is 2/3 vref where vref is either 5v or 3.3v. this is to preserve joystick compatibil ity by maintaining the rc time constant reset trigger voltage of 3.3v (nominal) with vref=5v (nominal), if required.
smsc ds ? LPC47M15X page 128 rev. 08/02/2001 6.18 hardware monito ring interface the hardware monitoring block is a standalone block in the wildwood2. it can be accessed using smbus interface. this block is used to monitor +1.5, +1.8, +2.5v, +3.3v, +5 v, +12v and vccp (core processor) voltages. it can also monitor its own internal hvcc or hvsb. the block can be used to measure internal temperature and two external temperatures and diode faults. it can indicate out-of-lim it temperature and voltage conditions. the block has an ability to output 20ms low pulse. 6.18.1 hardware monitoring interface signal definition the following table shows the pins required for the hardware monitoring block. pin name type description sda digital i/o (open drain) system management bus bi-directional data. open drain output. sclk digital input system management bus clock. hvss analog ground internally connected to all of the hardware monitoring block circuitry. hvcc power +3.3v hvcc pin dedicated to the hardware monitoring block. can be powered by +3.3v standby power if monitoring in low power states is required. vid0 digital input voltage supply readout from the processor. this value is read in the vid register. vid1 digital input voltage supply readout from the processor. this value is read in the vid register. vid2 digital input voltage supply readout from the processor. this value is read in the vid register. vid3 digital input voltage supply readout from the processor. this value is read in the vid register. d0-/xnor_in analog input/ digital input this is the negative input (current sink) from the remote thermal diode. this serves as the negative input into the a/d. if held high at power-up, initiates xnor chain test mode. d0+ analog input this is the positive input (cu rrent source) from the remote thermal diode. this serves as t he positive input into the a/d. d1- analog input see d0- pin description. d1+ analog input see d0+ description. 12v_in/vid4 analog input/ digital input defaults to analog input fo r +12v. optionally, can be configured to read the vid4 pin, a voltage supply readout from the processor. this value is read in the vid4 register. +5v_in analog input analog input for +5v +3.3v_in analog input analog input for +3.3v +2.5v_in analog input analog input for +2.5v +1.8v_in analog input analog input for +1.8v +1.5v_in analog input analog input for +1.5v +vccp_in analog input analog input for +vccp (processor voltage: 0 to 3.0v). a0/nreset/ ntherm/xnor_out digital i/o (open drain) the lowest order programmable bit of the smbus address. can also be configured to be a minimum 20msec low reset output pulse, or as an interr upt output for temperature and voltage interrupts. this pin f unctions as an output when the hardware monitor block is in xnor-chain test mode.
smsc ds ? LPC47M15X page 129 rev. 08/02/2001 6.18.2 smbus interface the host processor communicates with th e hardware monitor block through a series of read/write registers via the smbus interface. smbus is a serial communication prot ocol between a computer host and its peripheral devices. the smbus protocol includes a physical layer based on the i 2 c tm serial bus. the default power on smbus address is 010110x binary, wher e x reflects the state defined by the a0 pin. the a0/nreset/ntherm/xnor_out pin requires an external pul lup resistor if the nreset or ntherm functions are used. this limits the smbus address to 0101101 unless external circuitry is used to override the pull-up at power-up. 6.18.2.1 smbus slave interface the hardware monitor block smbus implementation is a subs et of the smbus interface to the host. the hardware monitor block is a slave-only smbus device. the implementation in the hardware monitor block is a subset of smbus since it only supports four protocols. the read byte, receive byte, write byte and send byte pr otocols are the only valid smbus protocols for the hardware monitor block. the part responds to other protocol s as described in the invalid protocol section. reference the system management bus specification, rev 1.1. the smbus interface is used to read and write the register s in the hardware monitor block. the only valid registers for a read or write protocol are the registers shown in the registers section. 6.18.2.1.1 bus protocols typical write byte, read byte, send byte and receive byte protocols are shown below. register accesses are performed using 7-bit slave addressing, an 8-bit register address field, and an 8-bit data field. the shading indicates the hardware monitor block driving data on the sda line; otherwise host data is on the sda line. the slave address is the unique smbus interface address for th e hardware monitor block that identifies it on smbus. the register address field is the internal address of the regist er to be accessed. the register data field is the data that the host is attempting to write to the r egister or the contents of the register that the hos t is attempting to read. data bytes are transferred msb first. when using the hardware monitor block smbus interface, a write will always consist of the smbus interface address byte, followed by the internal address register byte, then the data byte. there are two cases for a read: 1) the normal read protocol consists of a write to the hardware monitor block with the smbus interface address byte, followed by the internal addr ess register byte. then restart t he serial communication with a read consisting of the smbus interface address byte, followe d by the data byte read from the hardware monitor block. this can be accomplished by using the read byte protocol or by using the send byte protocol followed by the receive byte protocol. 2) if the internal address register is known to be at the desired address, simply read the hardware monitor block with the smbus interface address byte, followed by the data byte read from the hardware monitor block. this corresponds to the receive byte protocol. write byte the write byte protocol is used to write data to the registers. the data will only be written if the protocol shown in table 57 is performed correctly. only one byte is transferred at time for a write byte protocol. table 57 ? smbus write byte protocol field: start slave addr wr ack reg. addr ack reg. data ack stop bits: 1 7 1 1 8 1 8 1 1
smsc ds ? LPC47M15X page 130 rev. 08/02/2001 read byte the read byte protocol is used to read data from the re gisters. the data will only be r ead if the protocol shown in table 58 is performed correctly. only one byte is transferred at time for a read byte protocol. table 58 ? smbus read byte protocol field: start slave addr wr ack reg. addr ack start slave addr rd ack reg. data nack stop bits: 1 7 1 1 8 1 1 7 1 1 8 1 1 send byte the send byte protocol is used to set the internal address register to the correct register in the hardware monitor block. no data is transferred for a send byte protocol. th e send byte can be followed by the receive byte protocol described below in order to read data from the register. the send byte protocol cannot be used to write data - if data is to be written to a register then the write byte protocol must be used as described in subsection above. the send byte protocol is shown in the table below. table 59 ? smbus send byte protocol field: start slave addr wr ack reg. addr ack stop bits: 1 7 1 1 8 1 1 receive byte the receive byte protocol is used to read data from the registers when the register address is known to be at the desired address (using the internal address register). this is used when the register address has been written to the desired address using the send byte protocol. this can be used for successive reads of the same register. the data will only be read if the protocol sh own in table 4 is performed correctly. only one byte is transferred at time for a receive byte protocol. table 60 ? smbus receive byte protocol field: start slave addr rd ack reg. data nack stop bits: 1 7 1 1 8 1 1 6.18.2.1.2 slave address the slave address is the unique address for the hardware monitor block that identifies the device on smbus. the hardware monitor block?s slave address is determined by the level on the a0 pin. the level on this pin forms the lsb of the 7-bit address 0101_10x. this pin may be used to support up to 2 hardware monitor blocks in a given system. the upper 6 bits of the hardware monitor block?s slave address are hardwired in the hardware monitor block. 6.18.2.1.3 invalid protocol response behavior registers that are accessed with an invalid protocol will not be updated. a register will only be updated following a valid protocol. the only valid protocols are the read byte , receive byte and write byte protocols described above. the only valid slave address is determined by the level on the a0 pin as the lsb of the address 0101_10x. the only valid registers for a read or write protocol are the registers shown in the registers section. reserved registers are not considered valid registers. attempting to communicate with the hardware monitor bl ock over smbus with an invalid slave address, invalid register address or invalid protocol will result in no resp onse, and the smbus slave interface will return to the idle state. 6.18.2.1.4 general call address response the hardware monitor block will not respond to a general call address of 0000_000.
smsc ds ? LPC47M15X page 131 rev. 08/02/2001 6.18.2.1.5 slave device time-out the device will not time-out when sclk is held low longer than t time-out min = 25ms. 6.18.2.1.6 stretching the sclk signal the hardware monitor block supports stretching of the sclk by other devices on the smbus. the hardware monitor block does not stretch the sclk. 6.18.2.1.7 smbus timing the smbus slave interface complies with the smbus ac timi ng specification. see the smbus timing in the ?timing diagram? section. 6.18.2.1.8 bus reset sequence the smbus slave interface will reset and return to the idle state upon a start field followed immediately by a stop field. 6.18.2.1.9 smbus alert response address the hardware monitor block implements the smbalert# si gnal. the ntherm interrupt pin can be used as the smbalert#. smbalert# is used in conjunction with the smbus general call address, 0001 100. the hardware monitor block device can signal the host that it wants to talk by pulling the smbalert# low. the host processes the interrupt and simultaneously accesses all smbalert# devices through a modified receive byte operation with the alert response address (ara). the hard ware monitor block, which pulled smbalert# low, will acknowledge the alert response address and respond with its device address. the host performs a modified receive byte operation with the alert response address. the 7-bit device address provided by the hardware monitor block device is placed in the 7 most significant bits of the byte. the eighth bit can be a zero or one. table 61 ? modified smbus receive byte protocol response to ara field: start alert response address rd ack hw monitor block slave address nack stop bits: 1 7 1 1 8 1 1 after acknowledging the slave address, the hardware monitor block must disengage its smbalert# pulldown. if the condition that caused the in terrupt remains, the hardware monitor bloc k will reassert the smbalert# on the next monitoring cycle. 6.18.3 hardware monitoring block the following sub-sections describe the hardware monitoring block. 6.18.3.1 input monitoring the hardware monitor block?s monitoring function is started by writing a ?1? to the start bit in the configuration register (0x40). measured values from the analog inputs a nd temperature sensors are stor ed in the value registers. these values can be compared to the programmed limits in t he limit register via smbus interface. the out-of-limit and diode fault conditions are stored in the interrupt status registers.
smsc ds ? LPC47M15X page 132 rev. 08/02/2001 6.18.3.2 resetting the hardware monitoring block 6.18.3.2.1 power on reset all the registers in the hardware monitor block reset to a default value when power is applied to the block. the default state of the register is shown in the table in the register su mmary subsection. the default state of value or limit registers are not shown because these registers have indeterminate power on values. usually the first action after power up is to write limi ts into the limit registers. 6.18.3.2.2 soft reset setting bit 7 of the configuration register (0x40) performs a soft reset. this bit is self-clearing. soft reset performs reset on all the registers except the value and limit registers. 6.18.3.3 reset out pin the nreset function is multiplexed on a0/nreset/nth erm/xnor_out pin. upon power up, the hardware monitor block reads this pin as an address pin (low bit of the smbus address). the hardware monitor block latches the value of this pin as the low order bit of the smbus address. a reset pulse output function can be selected by writing a ?1? to bit 7 of the vid register (0x47). if bit 4 (reset) of configuration register (0x40) is set, nreset pin will out put a minimum 20ms low pulse. the reset bit is self- clearing. the nreset pin is open-drain and requires an exte rnal pullup resistor. if more than one hardware monitor block is used on a system, only one can have this function enabled at one time since this will limit the smbus address to 0101101, unless external circuitry is provided. 6.18.3.4 monitoring modes the hardware monitor block supports two monitoring modes: continuous mode and cycle mode. these modes are selected using bit 1 of the special function register (0x4f) . the following subsections contain a description of these monitoring modes. for each mode, there are two options for the number of me asurements that are perfor med on each temperature and voltage reading. these options are selected using bit 5 of the special function register (0x4f). these options are as follows: 1) 128 measurements are averaged for the remote dio de temperature reading and 8 measurements are averaged for all voltage and the internal temperatur e reading. this is the default operation. 2) 16 measurements are averaged for the remote diode tem perature reading and a single measurement is taken for all voltage and the internal temperature reading (i.e., no averaging). this is a power saving option. for option 1, the block performs a total of (2 x 128) + (1 x 8) + (8 x 8) = 328 conversions. (8 less if the 12v input is not selected i.e. 320). option 2 reduces the number of conversions to (2 x 16) + (1 x 1) + (8 x 1) = 41 (or 40 if the 12v input is not selected). each temperature conversion takes 1.688ms approx. an d each voltage conversion takes 1.511ms approx. the total time for option 1 (328 conversions) is (2x128x 1.688ms) + (1x8x1.688ms) + (8 x8x1.511ms) = 542.336ms. the total time for option 2 (41 conversions) is (2x16x 1.688ms) + (1x1x1.688ms) + (8x1x1.511ms) = 67.792ms. 6.18.3.4.1 continuous monitoring mode in the continuous monitoring mode, the sampling and conver sion process is performed continuously for each voltage and temperature reading after the start bit is set high. the time for each voltage and temperature reading is shown above for each measurement option. the continuous monitoring function is started by doing a writ e to the configuration register, setting the start bit (bit 0) high. the part then performs a ?round robin? sampling of the inputs, in the order shown below (corresponding to locations in the value ram). sampling of all values occurs in 542.336 ms (or 67.792ms - see above).
smsc ds ? LPC47M15X page 133 rev. 08/02/2001 sampling order register 1 remote diode temp reading 1 2 ambient temperature reading 3 hvcc/+3.3hvsb reading 4 +12v (if selected) reading 5 +5v reading 6 +3.3v reading 7 +2.5v reading 8 vccp (processor) reading 9 remote diode temp reading 2 10 +1.8v reading 11 +1.5v reading when the continuous monitoring function is started, it cycles through each measurement in sequence, and it continuously loops through the sequence approximately once every 542.336 ms (or 67.792ms ? see above). each measured value is compared to values stored in the limit registers. when the measured valu e violates (or is equal to) the programmed limit the hardware monitor block will set a co rresponding status bit in the interrupt status registers. the results of the sampling and conversions can be fo und in the value ram and are available at any time. 6.18.3.4.2 cycle monitoring mode in cycle monitoring mode, the part completes all samplin g and conversions, then waits to repeat the process. it repeats the sampling and conversion process every second (1 .4 sec max). the sampling and conversion of each voltage and temperature reading is performed once ever y monitoring cycle. this is a power saving mode. the cycle monitoring function is started by doing a write to the configuration register, setting the start bit (bit 0) high. the part then performs a ?round robin? sampling of the inputs, in the order shown above. when the cycle monitoring function is started, it cycles through each measurement in sequence, and it performs a single conversion for each voltage and temperature approx imately once every second. each measured value is compared to values stored in the limit registers. when t he measured value violates (or is equal to) the programmed limit the hardware monitor block will set a correspo nding status bit in the in terrupt status registers the results of each sampling and conversion can be found in the value ram and are available at any time, however, they are only updated once every 1-1.4 seconds. 6.18.3.5 interrupt status registers the hardware monitor block contains a pai r of interrupt status regi sters. these registers are used to reflect the state of all temperature and voltage out-of-lim it/equal-limit error conditions and diode fault conditions that the hardware monitor block monitors for. when an error occurs during t he conversion cycle, its corresponding bit is set in its respective interrupt status register. t he status register bits are updated conti nuously through each monitoring cycle. if a measurement is within (and not equal to) limits or if ther e is no diode fault, the corresponding status register bit will be cleared to ?0?. if the measurement is equal to the limit value or out of limit or if there is a diode fault, the corresponding status register bit will be set to ?1?. read ing the status register does not clear its contents. these registers default to 0x00 on hvcc por and initialization. 6.18.3.6 low power modes the hardware monitor block can be placed in a low-power m ode by writing a ?0? to the conf iguration register (0x40). the low power mode that is entered is either sleep mode or shutdown mode as selected using bit 0 of the special function register (4fh). these modes do not reset an y of the registers of the hardware monitor block. 6.18.3.6.1 sleep mode this is a low power mode in which bias currents are ?on? but the hardware monitor block is not operating. in this mode, the a/d converter and monitoring cycle will be turn ed off. serial bus communication is still possible with any register in the hardware monitor block while in this low-power mode.
smsc ds ? LPC47M15X page 134 rev. 08/02/2001 6.18.3.6.2 shutdown mode this is a low power mode in which bias currents are ?off? and the hardware monitor block is not operating. in this mode, the a/d converter and monitoring cycle will be turn ed off. serial bus communication is still possible with any register in the hardware monitor block while in this low-power mode. 6.18.3.7 analog voltage measurement the hardware monitor block contains inputs for directly moni toring the power supplies (+12 v, +5 v, +3.3v, +2.5v, +1.8v, +1.5v, +vccp and hvcc or hvsb). these inputs are scaled internally to a internal reference source, converted via a 8 bit successive approximation register adc or a delta-sigma adc (analog-to-digital converter), and scaled such that the correct value refers to 3/4 scale or 192 decimal (except the vccp input). this removes the need for external resistor dividers and allows for a more accurate means of measurement since the voltages are referenced to a known value. the 1.5v input requires external resistor divider. since these inputs are above vcc and below ground, they are not diode protected to the powe r rails. the measured values are stored in the reading registers and compared with the limit regi sters. the status bits in the interrupt status register 1 and the interrupt status register 2 are set if t he measured values are outside (or equal to) the programmed limits. the vccp voltage input measures t he processor voltage, which will lie in the range of 0v to 3.0v. the following table shows the values of the analog inputs that correspond to the min and max output codes of the a/d converter. for a complete list of the a dc conversions see table 78 in appendix b. input voltage +12v in +5v in hv cc /3.3v +2.5v in +1.8v in +1.5v in +v ccp min value (corresponds to a/d output 00000000) <0.062 <0.026 <0.017 <0. 013 <0.009 <0.008 <0.012 max value (corresponds to a/d output 11111111) >15.938 >6.640 >4.383 >3. 320 >2.391 >1.992 >2.988 6.18.3.8 voltage id vid0-vid4 digital inputs are used to st ore processor voltage id codes (for pr ocessor operating voltage) in the vid and vid4 registers (0x47 and 0x49). these vids can be read out by the management system using the smbus interface. bits[3:0] in vid register is used for vid3 to vi d0 inputs and bit[0] of vid4 register is used for vid4 input. vid4 input is multiplexed with +12v_in analog input. this pin defaults to the +12v_in analog input at power up and bit 0 in vid4 register defaults to 0. this pin can be se lected for vid4 by setting bit 5 in the configuration register (0x40). 6.18.3.9 temperature measurement temperatures are measured internally by bandgap temperature sensor and externally using two sets of diode sensor pins (for measuring two external temp eratures). see subsections below. 6.18.3.9.1 internal te mperature measurement internal temperature can be measured by bandgap temperat ure sensor. the measurement is converted into digital format by internal adc. this data is converted in two?s complement format since both negative and positive temperature can be measured. this value is stored in am bient temperature reading register (0x27). if this value out-of-limit (or equal to) the programmed limits in ambient temperature high limit regi ster (0x39) and ambient temperature low limit register (0x3a), then the correspondin g status bits in the interrupt status registers are set. 6.18.3.9.2 external temperature measurement the hardware monitor block also provides a way to meas ure two external temperatures using diode sensor pins (dx+ and dx-). the value is stored in the remote dio de temperature reading 1 register (0x26) for d0+ and d0- pins. the value is stored in the remote diode temperatur e reading 2 register (0x52) for d1+ and d1- pins. if this value is out-of-limit (or equal to) of the programmed limi ts (for d0+ and d0- pins, or d1+ and d1- pins) in remote temperature high limit 1 or 2 register and remote temperature low limit 1 or 2 register, then the remote temp error 1 or 2 status bit is set in the interrupt status register 1. there are remote diode fault status 1 and 2 bits in the status register 2 (0x4 2), which, when one, indicate a short or open-circuit on remote thermal diode inputs (dx+ and dx-). before a remote diode conversion is updated, the status of the remote diode is checked. the temperature change is computed by measuring the change in vbe at two di fferent operating points of the diode to which the dx+ and dx- pins are connected. but accuracy of the measurement also de pends on non-ideality factor
smsc ds ? LPC47M15X page 135 rev. 08/02/2001 of the process the diode is manufactured on. see ?appendix ? therma l diode parameters? for relationship between the non-ideality factor and the change in vbe. note: since digital boards can be electrically noisy envir onments that may interfere when measuring very small voltages from a remote diode sensor, special layout cons iderations should be made. see ?layout considerations? below. 6.18.3.9.3 temperature data format temperature data can be read from the three temperature registers. one is the ambient temperature reading register (0x27), the second is the re mote diode temperature reading 1 register (0x26), and the third is the remote diode temperature reading 2 register (0x52). the following table shows the corresponding format of the temperature digital data, represented by an 8-bit, two?s complement word with an lsb equal to 1.0 0 c. temperature digital output +125 0 c 0111 1101 +25 0 c 0001 1001 +1.0 0 c 0000 0001 0 0 c 0000 0000 -1.0 0 c 1111 1111 -25 0 c 1110 0111 -40 0 c 1101 1000 6.18.3.9.4 offset register offset register 1 is used for internal or remote temperature 1 reading. t he offset register 1 (1fh) contain a 2's complement value which is added (or subtracted if the num ber is negative) to the tem perature reading. the default value in the offset register is zero, so initially zero is always added to the temper ature reading. this offset register is configured for the external temperature channel by default. it may be switched to the internal channel by setting bit 4 of the special function register to 1. 6.18.3.9.5 second offset register the offset register 2 at 1eh is for second remote dio de temperature reading. this register contains a 2's complement value which is added (or subtracted if the num ber is negative) to the second external temperature reading. note that the default value in the offset register is zero, so initia lly zero is always added to the second temperature reading. this offset register only applies to re mote diode temperature reading 2. no configuration bit is required. 6.18.3.10 thermal / voltage interrupt pin the ntherm function is multiplexed on a0/nreset/ntherm/xn or_out pin. this function is used as an interrupt output for out-of-limit temperature events. it c an also be enabled for out-of-limit voltage events. if the internal or remote temperature reading is not within the low or high temperature limits, ntherm will be active low. it will also be low if the diode pins are left unconnecte d, since that will cause the temperature reading to reach the limit and set the remote temp error bits. this pin will remain low while any of the ambient temp error bit or the remote temp error bit in interrupt status 1 register is se t. the ntherm function can be selected by writing a ?1? to bit 2 of the special function register (0x4f). this pin is open-drain and requires an external pullup resistor. if more than one hardware monitor block is used on a system, only one can have this function enabled at one time since this will limit the smbus address to 0101101, unless external circuitry is provided. the ntherm pin can be enabled to indicate out-of-limit/equal- limit voltages. bit 3 of the special function register (4fh) is used to enable this option. when this bit is set, if one or more of the voltage readings is not within the low or high limits, ntherm will be active low. this pin will re main low while the associated voltage error bit (+2.5v_error, vccp_error, +3.3v_error, +5v_ error, +12v_error, hvcc_error, +1.5v_error or +1.8v_error) in the interrupt status register 1 and interrupt status register 2 is set. t he ntherm pin defaults to suppor ting out-of-limit/equal-limit temperature events only.
smsc ds ? LPC47M15X page 136 rev. 08/02/2001 the ntherm pin will remain low until interrupt status register 1 and 2 are read, when it will be cleared. if the temperature or voltage remains out of limit or equal to the limit , the ntherm will be re-asserted on the next monitoring cycle. ntherm can also be cleared by issuing an alert response address call. the ntherm pin may only become active while the monitor block is operational. implementation note: in designs using the hardware monitor block of the lp c47m15x, all the remote thermal diode inputs must be properly terminated, even if one or bo th of the remote temperature sensor channels will not be used to actively monitor temperatures. these inputs should be terminated wi th a thermal diode, a transistor or a resistor. if the channel will never be used to monitor temperature, a resist or can used to allow for proper functioning of the ntherm pin. see application note ?using the hardware monitor f eature in smsc super i/o devices? for more information. unused analog voltage channel inputs should not be left unconnected. this is good design practice, and it will guarantee proper functioning of the ntherm pin, if the nt herm pin is enabled to indicate voltages events. any analog voltage measurement channel that will not be used to actively monitor a power supply must be pulled up to some nominal voltage. if the ntherm pin is not enabl ed to indicate voltages events, unused analog voltage channels may be grounded. 6.18.3.11 input safety since the power supply voltages will appear directly at the pins (1.8v ? 12v), small external series resistors such as 470 ohm to 1k ohm (see note) should be put into the lines driving the chip to prevent damaging the traces or power supplies should an accidental short such as a probe connect two power supplies together. this value should be kept as small as possible, since raising this resistor will start a ffecting the accuracy of the internal dividers. these resistors are recommended, but not necessary. there is no internal resist or divider for 1.5v input, so the resistor divider must be provided externally. note: the analog input channels on the LPC47M15X are calibrated for 500 ohm resistors. these optional external resistors should not exceed 1k ? . 6.18.3.12 layout considerations to ensure accuracy when measuring analog signals, whether from a voltage divider or remote diode sensor, the analog components should be located physically as close to the hardware monitoring block as possible. the following is a list of precautions and suggestions to gain optimal performance from the hardware monitoring block. 1) devices that are sources of noise, such as generator s, data/address buses and crts should be kept as far away from the hardware monitoring block as possibl e. (aproximately 4 to 8 inches is adequate). 2) the dx+ and dx- tracks should be ke pt close together, in parallel with grounded guard tra cks on each side. using wide tracks will help to minimize inductance and reduce noise pickup. a 10 mil track minimum width and spacing is recommended. see figure 10. gnd gnd d+ d- 10 mil. 10 mil. 10 mil. 10 mil. 10 mil. 10 mil. 10 mil. figure 10 ? suggested minimum track width and spacing
smsc ds ? LPC47M15X page 137 rev. 08/02/2001 3) to reduce the effects of noise on the dx+ and dx- sign als, a 2.2nf capacitor may be place between these two leads. dx+ dx- 2.2nf external temperature sensing diode figure 11 ? using a diode as a remote temperature sensing element 4) place 0.1uf (ceramic) bypass and 20uf (electrolytic or tantalum) capacitors in parallel between the power supply (hvcc) and ground. they should be kept as close to the hardware monitoring block as possible.
smsc ds ? LPC47M15X page 138 rev. 08/02/2001 7. runtime registers the following registers are runtime regi sters in the LPC47M15X. they are lo cated at the address programmed in the base i/o address in logical device a (also referred to as t he runtime register) at the offs et shown. these registers are powered by vtr. table 62 ? runtime register block summary register offset (hex) type hard reset vcc por vtr por soft reset register 00 r/w - - 0x00 - pme_sts 01 r - - - - reserved ? reads return 0 02 r/w - - 0x00 - pme_en 03 r - - - - reserved ? reads return 0 04 r/w - - 0x00 - pme_sts1 05 r/w - - 0x00 - pme_sts2 06 r/w - - 0x00 - pme_sts3 07 r/w - - 0x00 (note 5) - pme_sts4 08 r/w - - 0x00 (note 5) - pme_sts5 09 r - - - - reserved ? reads return 0 0a r/w - - 0x00 - pme_en1 0b r/w - - 0x00 - pme_en2 0c r/w - - 0x00 - pme_en3 0d r/w - - 0x00 - pme_en4 0e r/w - - 0x00 - pme_en5 0f r - - - - reserved ? reads return 0 10 r/w - (note 4) - (note 4) 0x02 (note 4) - (note 4) smi_sts 1 11 r/w - - 0x00 - smi_sts 2 12 r/w - - 0x00 - smi_sts3 13 r/w - - 0x00 (note 5) - smi_sts4 14 r/w - - 0x00 - smi_sts5 15 r - - - - reserved ? reads return 0 16 r/w - - 0x00 - smi_en1 17 r/w - - 0x00 - smi_en2 18 r/w - - 0x00 - smi_en3 19 r/w - - 0x00 - smi_en4 1a r/w - - 0x00 - smi_en5 1b r - - - - reserved ? reads return 0 1c r/w - - 0x00 - msc_sts 1d r - - - - reserved ? reads return 0 1e r/w 0x03 0x03 0x03 - force disk change 1f r - - - - floppy data rate select shadow 20 r - - - - uart1 fifo control shadow 21 r - - - - uart2 fifo control shadow 22 r/w (note 1) - - 0x00 - device disable register 23 r/w - - 0x01 - gp10 24 r/w - - 0x01 - gp11 25 r/w - - 0x01 - gp12
smsc ds ? LPC47M15X page 139 rev. 08/02/2001 register offset (hex) type hard reset vcc por vtr por soft reset register 26 r/w - - 0x01 - gp13 27 r/w - - 0x01 - gp14 28 r/w - - 0x01 - gp15 29 r/w - - 0x01 - gp16 2a r/w - - 0x01 - gp17 2b r/w - - 0x01 - gp20 2c r/w - - 0x01 - gp21 2d r/w - - 0x01 - gp22 2e r - - - - reserved ? reads return 0 2f r/w - - 0x01 - gp24 30 r/w - - 0x01 - gp25 31 r/w - - 0x01 - gp26 32 r/w - - 0x01 - gp27 33 r/w - - 0x01 - gp30 34 r/w - - 0x01 - gp31 35 r/w 0x00 0x00 0x01 - gp32 36 r/w 0x00 0x00 0x01 - gp33 37 r/w - - 0x05 - gp34 38 r/w 0x04 0x04 0x04 - gp35 39 r/w - - 0x01 - gp36 3a r/w - - 0x01 - gp37 3b r/w - - 0x01 - gp40 3c r/w - - 0x01 - gp41 3d r/w - - 0x01 - gp42 3e r/w - (note 2) - (note 2) 0x01 - gp43 3f r/w - - 0x01 - gp50 40 r/w - - 0x01 - gp51 41 r/w - - 0x01 - gp52 42 r/w 0x00 0x00 0x00 - gp53 43 r/w - - 0x01 - gp54 44 r/w - - 0x01 - gp55 45 r/w - - 0x01 - gp56 46 r/w - - 0x01 - gp57 47 r/w - - 0x01 - gp60 48 r/w - - 0x01 - gp61 49 r - - - - reserved ? reads return 0 4a r - - - - reserved ? reads return 0 4b r/w - - 0x00 - gp1 4c r/w - - 0x00 - gp2 4d r/w - (note 2) - (note 2) 0x00 - gp3 4e r/w - - 0x00 - gp4 4f r/w - (note 3) - (note 3) 0x00 - gp5 50 r/w - - 0x00 - gp6 51 r - - - - reserved ? reads return 0 52 r - - - - reserved ? reads return 0
smsc ds ? LPC47M15X page 140 rev. 08/02/2001 register offset (hex) type hard reset vcc por vtr por soft reset register 53 r - - - - reserved ? reads return 0 54 r - - - - reserved ? reads return 0 55 r - - - - reserved ? reads return 0 56 r/w - - 0x00 - fan1 57 r/w - - 0x00 - fan2 58 r/w - - 0x50 - fan control 59 r - - 0x00 - fan1 tachometer register 5a r - - 0x00 - fan2 tachometer register 5b r/w - - 0x00 - fan1 preload register 5c r/w - - 0x00 - fan2 preload register 5d r/w - - 0x00 - led1 5e r/w - - 0x00 - led2 5f r/w - - 0x00 - keyboard scan code 60-7f r - - - - reserved ? reads return 0 note 1: this register is read-only when gp43 register bit [3:2] = 01 and the gp43 pin is high. note 2: bits [3:2] of this register are reset (cl eared) on vcc por and hard reset (and vtr por). note 3: bit 3 of this register is reset (clear ed) on vcc por and hard reset (and vtr por). note 4: the parallel port interrupt defaults to 1 when the parallel port activate bit is cleared. note 5: bits 2 and 3 of the pme_sts4 and smi_sts4 registers, and bit 3 of the pme_sts5 register may be set on a vcc por. if gp32, gp33 and gp53 are configured as input, then their co rresponding pme and smi status bits will be set on a vcc por. these gpios cannot be us ed for pme wakeup when the part is under vtr power (vcc=0).
smsc ds ? LPC47M15X page 141 rev. 08/02/2001 the following registers are located at an offset from (pme_blk) the addre ss programmed into the base i/o address register for logical device a. table 63 ? runtime register block description name reg offset (hex) description pme_sts default = 0x00 on vtr por 00 (r/w) bit[0] pme_status = 0 (default) = 1 set when LPC47M15X would normally assert the nio_pme signal, independent of the state of the pme_en bit. bit[7:1] reserved pme_status is not affected by vcc por, soft reset or hard reset. writing a ?1? to pme_status will clear it and cause the LPC47M15X to stop asserting nio_pme, in enabl ed. writing a ?0? to pme_status has no effect. n/a 01 (r) bits[7:0] reserved ? reads return 0 pme_en default = 0x00 on vtr por 02 (r/w) bit[0] pme_en = 0 nio_pme signal assertion is disabled (default) = 1 enables LPC47M15X to assert nio_pme signal bit[7:1] reserved pme_en is not affected by vcc por, soft reset or hard reset n/a 03 (r) bits[7:0] reserved ? reads return 0 pme_sts1 default = 0x00 on vtr por 04 (r/w) pme wake status register 1 this register indicates the state of the individual pme wake sources, independent of the individual source enables or the pme_en bit. if the wake source has asserted a wake event, the associated pme wake status bit will be a ?1?. bit[0] reserved (note 7) bit[1] ri2 bit[2] ri1 bit[3] kbd bit[4] mouse bit[5] spekey (wake on specific key) bit[6] fan_tach1 bit[7] fan_tach2 the pme wake status register is not affected by vcc por, soft reset or hard reset. writing a ?1? to bit[7:0] will clear it. writing a ?0? to any bit in pme wake status register has no effect.
smsc ds ? LPC47M15X page 142 rev. 08/02/2001 name reg offset (hex) description pme_sts2 default = 0x00 on vtr por 05 (r/w) pme wake status register 2 this register indicates the state of the individual pme wake sources, independent of the individual source enables or the pme_en bit. if the wake source has asserted a wake event, the associated pme wake status bit will be a ?1?. bit[0] gp10 bit[1] gp11 bit[2] gp12 bit[3] gp13 bit[4] gp14 bit[5] gp15 bit[6] gp16 bit[7] gp17 the pme wake status register is not affected by vcc por, soft reset or hard reset. writing a ?1? to bit[7:0] will clear it. writing a ?0? to any bit in pme wake status register has no effect. pme_sts3 default = 0x00 on vtr por 06 (r/w) pme wake status register 3 this register indicates the state of the individual pme wake sources, independent of the individual source enables or the pme_en bit. if the wake source has asserted a wake event, the associated pme wake status bit will be a ?1?. bit[0] gp20 bit[1] gp21 bit[2] gp22 bit[3] devint_sts (status of group smi signal for pme) bit[4] gp24 bit[5] gp25 bit[6] gp26 bit[7] gp27 the pme wake status register is not affected by vcc por, soft reset or hard reset. writing a ?1? to bit[7:0] will clear it. writing a ?0? to any bit in pme wake status register has no effect. pme_sts4 default = 0x00 on vtr por (note 6) 07 (r/w) pme wake status register 4 this register indicates the state of the individual pme wake sources, independent of the individual source enables or the pme_en bit. if the wake source has asserted a wake event, the associated pme wake status bit will be a ?1?. bit[0] gp30 bit[1] gp31 bit[2] gp32 bit[3] gp33 bit[4] gp41 bit[5] gp43 bit[6] gp60 bit[7] gp61 the pme wake status register is not affected by vcc por, soft reset or hard reset. writing a ?1? to bit[7:0] will clear it. writing a ?0? to any bit in pme wake status register has no effect.
smsc ds ? LPC47M15X page 143 rev. 08/02/2001 name reg offset (hex) description pme_sts5 default = 0x00 on vtr por (note 6) 08 (r/w) pme wake status register 5 this register indicates the state of the individual pme wake sources, independent of the individual source enables or the pme_en bit. if the wake source has asserted a wake event, the associated pme wake status bit will be a ?1?. bit[0] gp50 bit[1] gp51 bit[2] gp52 bit[3] gp53 bit[4] gp54 bit[5] gp55 bit[6] gp56 bit[7] gp57 the pme wake status register is not affected by vcc por, soft reset or hard reset. writing a ?1? to bit[7:0] will clear it. writing a ?0? to any bit in pme wake status register has no effect. n/a 09 (r) bits[7:0] reserved ? reads return 0 pme_en1 default = 0x00 on vtr por 0a (r/w) pme wake enable register 1 this register is used to enable individual LPC47M15X pme wake sources onto the nio_pme wake bus. when the pme wake enable register bit for a wake source is active (?1?), if the source asserts a wa ke event so that the associated status bit is ?1? and the pme_en bit is ?1?, the source will assert the nio_pme signal. when the pme wake enable register bit for a wake source is inactive (?0?), the pme wake status register will indicate the state of the wake source but will not assert the nio_pme signal. bit[0] reserved (note 7) bit[1] ri2 bit[2] ri1 bit[3] kbd bit[4] mouse bit[5] spekey (wake on specific key) bit[6] fan_tach1 bit[7] fan_tach2 the pme wake enable register is not affected by vcc por, soft reset or hard reset.
smsc ds ? LPC47M15X page 144 rev. 08/02/2001 name reg offset (hex) description pme_en2 default = 0x00 on vtr por 0b (r/w) pme wake enable register 2 this register is used to enable individual LPC47M15X pme wake sources onto the nio_pme wake bus. when the pme wake enable register bit for a wake source is active (?1?), if the source asserts a wa ke event so that the associated status bit is ?1? and the pme_en bit is ?1?, the source will assert the nio_pme signal. when the pme wake enable register bit for a wake source is inactive (?0?), the pme wake status register will indicate the state of the wake source but will not assert the nio_pme signal. bit[0] gp10 bit[1] gp11 bit[2] gp12 bit[3] gp13 bit[4] gp14 bit[5] gp15 bit[6] gp16 bit[7] gp17 the pme wake enable register is not affected by vcc por, soft reset or hard reset. pme_en3 default = 0x00 on vtr por 0c (r/w) pme wake status register 3 this register is used to enable individual LPC47M15X pme wake sources onto the nio_pme wake bus. when the pme wake enable register bit for a wake source is active (?1?), if the source asserts a wa ke event so that the associated status bit is ?1? and the pme_en bit is ?1?, the source will assert the nio_pme signal. when the pme wake enable register bit for a wake source is inactive (?0?), the pme wake status register will indicate the state of the wake source but will not assert the nio_pme signal. bit[0] gp20 bit[1] gp21 bit[2] gp22 bit[3] devint_en (enable bit fo r group smi signal for pme) bit[4] gp24 bit[5] gp25 bit[6] gp26 bit[7] gp27 the pme wake enable register is not affected by vcc por, soft reset or hard reset.
smsc ds ? LPC47M15X page 145 rev. 08/02/2001 name reg offset (hex) description pme_en4 default = 0x00 on vtr por 0d (r/w) pme wake enable register 4 this register is used to enable individual LPC47M15X pme wake sources onto the nio_pme wake bus. when the pme wake enable register bit for a wake source is active (?1?), if the source asserts a wa ke event so that the associated status bit is ?1? and the pme_en bit is ?1?, the source will assert the nio_pme signal. when the pme wake enable register bit for a wake source is inactive (?0?), the pme wake status register will indicate the state of the wake source but will not assert the nio_pme signal. bit[0] gp30 bit[1] gp31 bit[2] gp32 bit[3] gp33 bit[4] gp41 bit[5] gp43 bit[6] gp60 bit[7] gp61 the pme wake enable register is not affected by vcc por, soft reset or hard reset. pme_en5 default = 0x00 on vtr por 0e (r/w) pme wake enable register 5 this register is used to enable individual LPC47M15X pme wake sources onto the nio_pme wake bus. when the pme wake enable register bit for a wake source is active (?1?), if the source asserts a wa ke event so that the associated status bit is ?1? and the pme_en bit is ?1?, the source will assert the nio_pme signal. when the pme wake enable register bit for a wake source is inactive (?0?), the pme wake status register will indicate the state of the wake source but will not assert the nio_pme signal. bit[0] gp50 bit[1] gp51 bit[2] gp52 bit[3] gp53 bit[4] gp54 bit[5] gp55 bit[6] gp56 bit[7] gp57 the pme wake enable register is not affected by vcc por, soft reset or hard reset. n/a 0f (r) bits[7:0] reserved ? reads return 0
smsc ds ? LPC47M15X page 146 rev. 08/02/2001 name reg offset (hex) description smi_sts1 default = 0x02 on vtr por bit 1 is set to ?1? on vcc por, vtr por, hard reset and soft reset 10 (r/w) smi status register 1 this register is used to read the status of the smi inputs. the following bits must be cleared at their source. bit[0] reserved bit[1] pint. the parallel port interrupt defaults to ?1? when the parallel port activate bit is cleared. when the parallel port is activated, pint follows the nack input. bit[2] u2int bit[3] u1int bit[4] fint bit[5] mpu-401 int bit[6] reserved bit[7] reserved (note 7) smi_sts2 default = 0x00 on vtr por 11 (r/w) smi status register 2 this register is used to read the status of the smi inputs. bit[0] mint. cleared at source. bit[1] kint. cleared at source. bit[2] irint. this bit is set by a transition on the ir pin (irrx or irrx2 as selected in cr l5-f1-b6 i.e., after the mux). cleared by a read of this register. bit[3] reserved bit[4] p12. status bit is cleared by a write of ?1?. the smi event is cleared at source. bit[7:5] reserved smi_sts3 default = 0x00 on vtr por 12 (r/w) smi status register 3 this register is used to read the status of the smi inputs. the following bits are cleared on a write of ?1?. bit[0] gp20 bit[1] gp21 bit[2] gp22 bit[3] reserved bit[4] gp24 bit[5] gp25 bit[6] gp26 bit[7] gp60 smi_sts4 default = 0x00 on vtr por (note 6) 13 (r/w) smi status register 4 this register is used to read the status of the smi inputs. the following bits are cleared on a write of ?1?. bit[0] gp30 bit[1] gp31 bit[2] gp32 bit[3] gp33 bit[4] gp41 bit[5] gp42 bit[6] gp43 bit[7] gp61
smsc ds ? LPC47M15X page 147 rev. 08/02/2001 name reg offset (hex) description smi_sts5 default = 0x00 on vtr por 14 (r/w) smi status register 5 this register is used to read the status of the smi inputs. the following bits are cleared on a write of ?1?. bit[0] gp54 bit[1] gp55 bit[2] gp56 bit[3] gp57 bit[4] reserved bit[5] reserved bit[6] fan_tach1 bit[7] fan_tach2 n/a 15 (r) bits[7:0] reserved ? reads return 0 smi_en1 default = 0x00 on vtr por 16 (r/w) smi enable register 1 this register is used to enable the different interrupt sources onto the group nsmi output. 1=enable 0=disable bit[0] reserved bit[1] en_pint bit[2] en_u2int bit[3] en_u1int bit[4] en_fint bit[5] en_mpu-401 int bit[6] reserved bit[7] reserved (note 7) smi_en2 default = 0x00 on vtr por 17 (r/w) smi enable register 2 this register is used to enable the different interrupt sources onto the group nsmi output, and the group nsmi output onto the nio_smi gpi/o pin, the serial irq stream or into the pme logic. unless otherwise noted, 1=enable 0=disable bit[0] en_mint bit[1] en_kint bit[2] en_irint bit[3] reserved bit[4] en_p12 bit[5] en_smi_pme (enable group smi into pme logic) bit[6] en_smi_s (enable group smi onto serial irq) bit[7] en_smi (enable group smi onto nio_smi pin)
smsc ds ? LPC47M15X page 148 rev. 08/02/2001 name reg offset (hex) description smi_en3 default = 0x00 on vtr por 18 (r/w) smi enable register 3 this register is used to enable the different interrupt sources onto the group nsmi output. 1=enable 0=disable bit[0] gp20 bit[1] gp21 bit[2] gp22 bit[3] reserved bit[4] gp24 bit[5] gp25 bit[6] gp26 bit[7] gp60 smi_en4 default = 0x00 on vtr por 19 (r/w) smi enable register 4 this register is used to enable the different interrupt sources onto the group nsmi output. 1=enable 0=disable bit[0] gp30 bit[1] gp31 bit[2] gp32 bit[3] gp33 bit[4] gp41 bit[5] gp42 bit[6] gp43 bit[7] gp61 smi_en5 default = 0x00 on vtr por 1a (r/w) smi enable register 5 this register is used to enable the different interrupt sources onto the group nsmi output. 1=enable 0=disable bit[0] gp54 bit[1] gp55 bit[2] gp56 bit[3] gp57 bit[4] reserved bit[5] reserved bit[6] fan_tach1 bit[7] fan_tach2 n/a 1b (r) bits[7:0] reserved ? reads return 0
smsc ds ? LPC47M15X page 149 rev. 08/02/2001 name reg offset (hex) description msc_sts default = 0x00 on vtr por 1c (r/w) miscellaneous status register bits[5:0] can be cleared by writing a 1 to their position (writing a 0 has no effect). bit[0] either edge triggered interrupt input 0 status. this bit is set when an edge occurs on the gp21 pin. bit[1] either edge triggered interrupt input 1 status. this bit is set when an edge occurs on the gp22 pin. bit[2] either edge triggered interrupt input 2 status. this bit is set when an edge occurs on the gp41 pin. bit[3] either edge triggered interrupt input 3 status. this bit is set when an edge occurs on the gp43 pin. bit[4] either edge triggered interrupt input 4 status. this bit is set when an edge occurs on the gp60 pin. bit[5] either edge triggered interrupt input 5 status. this bit is set when an edge occurs on the gp61 pin. bit[7:6] reserved. this bit always returns zero. n/a 1d (r) bits[7:0] reserved ? reads return 0 force disk change default = 0x03 on vcc por, hard reset and vtr por 1e (r/w) force disk change bit[0] force disk change for fdc0 0=inactive 1=active bit[1] force disk change for fdc1 0=inactive 1=active force change 0 and 1 can be written to 1 but are not clearable by software. force change 0 is cleared on nstep and nds0 force change 1 is cleared on nstep and nds1 dskchg (fdc dir register, bit 7) = (nds0 and force change 0) or (nds1 and force change 1) or ndskchg setting either of the force disk change bits active ?1? forces the fdd ndskchg input active when the appropriate drive has been selected. bit[7:2] reserved floppy data rate select shadow 1f (r) floppy data rate select shadow bit[0] data rate select 0 bit[1] data rate select 1 bit[2] precomp 0 bit[3] precomp 1 bit[4] precomp 2 bit[5] reserved bit[6] power down bit[7] soft reset
smsc ds ? LPC47M15X page 150 rev. 08/02/2001 name reg offset (hex) description uart1 fifo control shadow 20 (r) uart fifo control shadow 1 bit[0] fifo enable bit[1] rcvr fifo reset bit[2] xmit fifo reset bit[3] dma mode select bit[5:4] reserved bit[6] rcvr trigger (lsb) bit[7] rcvr trigger (msb) uart2 fifo control shadow 21 (r) uart fifo control shadow 2 bit[0] fifo enable bit[1] rcvr fifo reset bit[2] xmit fifo reset bit[3] dma mode select bit[5:4] reserved bit[6] rcvr trigger (lsb) bit[7] rcvr trigger (msb) device disable register default = 0x00 vtr por 22 read/write when gp43 register bits[3:2] = 01 and gp43 pin = 0 or gp43 register bits[3:2] 01 read-only when gp43 register bits[3:2] =01 and gp43 pin = 1 if ?0? (enabled), bits[7:3] have no effect on the devices; devices are controlled by their respec tive activate bits. if ?1? (disabled), bits[7:3] overri de the activate bits in the configuration registers for each logical block. bit[0]: floppy write protect. 0= no effect: floppy write protection is controlled by the write protect pin or the forced write protect bit (b it 0 of register 0xf1 in logical device 0); 1= write protected. if set to 1, this bit overrides the write protect pin on the part and the forced write protect bit. nwrtprt (to the fdc core) = (nds0 and force write protect) or (nds1 and force write protect)or nwrtprt (from the fdd interface) or floppy write protect note : the force write protect bit is in the fdd option configuration register. bits[2:1]: reserved. return 0 on read. bit[3]: floppy enable. 0=no effect: fdc controlled by its activate bit; 1=floppy disabled bit[4]: mpu-401 serial port enable. 0=no effect: mpu-401 uart controlled by its activate bit; 1=mpu-401 uart disabled bit[5]: serial port 2 enable. 0=no effect: uart2 controlled by its activate bit; 1=uart2 disabled bit[6]: serial port 1 enable. 0=no effect: uart1 controlled by its activate bit; 1=uart1 disabled bit[7]: parallel port enable. 0=no effect: pp controle d by its activate bit; 1=pp disabled
smsc ds ? LPC47M15X page 151 rev. 08/02/2001 name reg offset (hex) description gp10 default = 0x01 on vtr por 23 (r/w) general purpose i/0 bit 1.0 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=j1b1 (joystick 1, button 1) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp11 default = 0x01 on vtr por 24 (r/w) general purpose i/0 bit 1.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j1b2 (joystick 1, button 2) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp12 default = 0x01 on vtr por 25 (r/w) general purpose i/0 bit 1.2 bit[0] in/out : =1 input, =0 output bit[1] polarity :=1 invert, =0 no invert bit[2] alternate function select 1= j2b1 (joystick 2, button 1) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp13 default = 0x01 on vtr por 26 (r/w) general purpose i/0 bit 1.3 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j2b2 (joystick 2, button 2) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp14 default = 0x01 on vtr por 27 (r/w) general purpose i/0 bit 1.4 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j1x (joystick 1, x-axis rc constant) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 152 rev. 08/02/2001 name reg offset (hex) description gp15 default = 0x01 on vtr por 28 (r/w) general purpose i/0 bit 1.5 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j1y (joystick 1, y-axis rc constant) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp16 default = 0x01 on vtr por 29 (r/w) general purpose i/0 bit 1.6 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j2x (joystick 2, x-axis rc constant) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp17 default = 0x01 on vtr por 2a (r/w) general purpose i/0 bit 1.7 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= j2y (joystick 2, y-axis rc constant) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp20 default = 0x01 on vtr por 2b (r/w) general purpose i/0 bit 2.0 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=8042 p17 function (user note 2) 0=basic gpio function bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 153 rev. 08/02/2001 name reg offset (hex) description gp21 default =0x01 on vtr por 2c (r/w) general purpose i/0 bit 2.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11= nds1 ? floppy drive select 1 (note 4) 10=either edge triggered interrupt input 0 (note 1) 01=8042 p16 function (user note 2) 00=basic gpio function bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp22 default =0x01 on vtr por 2d (r/w) general purpose i/0 bit 2.2 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11= nmtr1 ? floppy motor select 1 (note 4) 10=either edge triggered interrupt input 1 (note 1), 01=8042 p12 function (user note 2) 00=basic gpio function bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull n/a 2e (r) bits[7:0] reserved ? reads return 0 gp24 default = 0x01 on vtr por 2f (r/w) general purpose i/0 bit 2.4 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] reserved bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp25 default = 0x01 on vtr por 30 (r/w) general purpose i/0 bit 2.5 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=midi_in 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 154 rev. 08/02/2001 name reg offset (hex) description gp26 default = 0x01 on vtr por 31 (r/w) general purpose i/0 bit 2.6 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=midi_out 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp27 default = 0x01 on vtr por 32 (r/w) general purpose i/0 bit 2.7 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=nio_smi (note 5) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp30 default = 0x01 on vtr por 33 (r/w) general purpose i/0 bit 3.0 bit[0] in/out : =1 input, =0 output bit[1] polarity :=1 invert, =0 no invert bit[2] alternate function select 1=fan_tach2 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp31 default = 0x01 on vtr por 34 (r/w) general purpose i/0 bit 3.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=fan_tach1 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp32 default = 0x01 on vtr por default = 0x00 on vcc por and hard reset (note 3) 35 (r/w) general purpose i/0 bit 3.2 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=fan2 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 155 rev. 08/02/2001 name reg offset (hex) description gp33 default = 0x01 on vtr por default = 0x00 on vcc por and hard reset (note 3) 36 (r/w) general purpose i/0 bit 3.3 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=fan1 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp34 default = 0x05 on vtr por 37 (r/w) general purpose i/0 bit 3.4 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=irrx2 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp35 default = 0x04 on vtr por, vcc por and hard reset (note 3) 38 (r/w) general purpose i/0 bit 3.5 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=irtx2 (note 2) 0=gpio bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp36 default = 0x01 on vtr por 39 (r/w) general purpose i/0 bit 3.6 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1= nkbdrst 0=basic gpio function bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp37 default = 0x01 on vtr por 3a (r/w) general purpose i/0 bit 3.7 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=a20m 0=basic gpio function bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 156 rev. 08/02/2001 name reg offset (hex) description gp40 default =0x01 on vtr por 3b (r/w) general purpose i/0 bit 4.0 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=drvden0 (note 4) 0=basic gpio function bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull gp41 default =0x01 on vtr por 3c (r/w) general purpose i/0 bit 4.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=either edge triggered interrupt input 2 (note 1) 01=drvden1 (note 4) 00=basic gpio function bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp42 default =0x01 on vtr por 3d (r/w) general purpose i/0 bit 4.2 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[2] alternate function select 1=nio_pme note: configuring this pin function as output with non-inverted polarity will give an active low output signal. the output type can be either open drain or push-pull. 0=basic gpio function bits[6:3] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 157 rev. 08/02/2001 name reg offset (hex) description gp43 default = 0x01 on vtr por bits[3:2] are reset (cleared) on vcc por, vtr por and hard reset 3e (r/w) general purpose i/0 bit 4.3 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=either edge triggered interrupt input 3 (note 1) 10=reserved 01=device disable register control. the gp43 pin is an input, with non-inverted polarity. when bits[3:2]=01, they cannot be changed by writing to these bits; they are cleared by vcc por, hard reset and vtr por. that is, when the ddrc function is selected for this pin, it cannot be changed, except by a vcc por, hard reset or vtr por. the device disable register is controlled by the value of the gp43 pin as follows: if the gp43 pin is high, the device disable register is read-only. if the gp43 pin is low, the device disable register is read/write. 00=basic gpio function bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp50 default = 0x01 on vtr por 3f (r/w) general purpose i/0 bit 5.0 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=nri2 (user note 1) 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp51 default = 0x01 on vtr por 40 (r/w) general purpose i/0 bit 5.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=ndcd2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 158 rev. 08/02/2001 name reg offset (hex) description gp52 default = 0x01 on vtr por 41 (r/w) general purpose i/0 bit 5.2 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=rxd2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp53 default = 0x00 on vtr por, vcc por and hard reset (note 3) 42 (r/w) general purpose i/0 bit 5.3 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=txd2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp54 default = 0x01 on vtr por 43 (r/w) general purpose i/0 bit 5.4 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=ndsr2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp55 default = 0x01 on vtr por 44 (r/w) general purpose i/0 bit 5.5 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=nrts2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull
smsc ds ? LPC47M15X page 159 rev. 08/02/2001 name reg offset (hex) description gp56 default = 0x01 on vtr por 45 (r/w) general purpose i/0 bit 5.6 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=ncts2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp57 default = 0x01 on vtr por 46 (r/w) general purpose i/0 bit 5.7 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=reserved 01=ndtr2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp60 default = 0x01 on vtr por 47 (r/w) general purpose i/0 bit 6.0 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=either edge triggered interrupt input 4 (note 1) 01=led1 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull gp61 default = 0x01 on vtr por 48 (r/w) general purpose i/0 bit 6.1 bit[0] in/out : =1 input, =0 output bit[1] polarity : =1 invert, =0 no invert bit[3:2] alternate function select 11=reserved 10=either edge triggered interrupt input 5 (note 1) 01=led2 00=gpio bits[6:4] reserved bit[7] output type select 1=open drain 0=push pull n/a 49 ? 4a (r) bits[7:0] reserved ? reads return 0
smsc ds ? LPC47M15X page 160 rev. 08/02/2001 name reg offset (hex) description gp1 default = 0x00 on vtr por 4b (r/w) general purpose i/0 data register 1 bit[0] gp10 bit[1] gp11 bit[2] gp12 bit[3] gp13 bit[4] gp14 bit[5] gp15 bit[6] gp16 bit[7] gp17 gp2 default = 0x00 on vtr por 4c (r/w) general purpose i/0 data register 2 bit[0] gp20 bit[1] gp21 bit[2] gp22 bit[3] reserved bit[4] gp24 bit[5] gp25 bit[6] gp26 bit[7] gp27 gp3 default = 0x00 on vtr por bits 2 and 3 are reset on vcc por, hard reset and vtr por 4d (r/w) general purpose i/0 data register 3 bit[0] gp30 bit[1] gp31 bit[2] gp32 bit[3] gp33 bit[4] gp34 bit[5] gp35 bit[6] gp36 bit[7] gp37 gp4 default = 0x00 on vtr por 4e (r/w) general purpose i/0 data register 4 bit[0] gp40 bit[1] gp41 bit[2] gp42 bit[3] gp43 bit[7:4] reserved gp5 default = 0x00 on vtr por bit 3 is reset on vcc por, hard reset and vtr por 4f (r/w) general purpose i/0 data register 5 bit[0] gp50 bit[1] gp51 bit[2] gp52 bit[3] gp53 bit[4] gp54 bit[5] gp55 bit[6] gp56 bit[7] gp57 gp6 default = 0x00 on vtr por 50 (r/w) general purpose i/0 data register 6 bit[0] gp60 bit[1] gp61 bit[7:2] reserved n/a 51 ? 55 (r) bits[7:0] reserved ? reads return 0
smsc ds ? LPC47M15X page 161 rev. 08/02/2001 name reg offset (hex) description fan1 default=0x00 on vtr por 56 (r/w) fan register 1 bit[0] fan control 1=fan1 pin is high 0=bits[6:1] control the duty cycle of the fan1 pin. bit[6:1] duty cycle control for fan1 control the duty cycle of the fan1 pin 000000 = pin is low 100000 = 50% duty cycle 111111 = pin is high for 63, low for 1 bit[7] fan 1 clock select this bit is used with the fan 1 clock source select and the fan 1 clock multiplier bits in the fan c ontrol register (0x58) to determine the fan speed f out . see table 56 in ?fan speed control and monitoring? section. the fan speed may be doubled through bit 2 of fan control register at 0x58. fan2 default = 0x00 on vtr por 57 (r/w) fan register 2 bit[0] fan control 1=fan2 pin is high 0=bits[6:1] control the duty cycle of the fan2 pin. bit[6:1] duty cycle control for fan2 control the duty cycle of the fan2 pin 000000 = pin is low 100000 = 50% duty cycle 111111 = pin is high for 63, low for 1 bit[7] fan 2 clock select this bit is used with the fan 2 clock source select and the fan 2 clock multiplier bits in the fan c ontrol register (0x58) to determine the fan speed f out . see table 56 in ?fan speed control and monitoring? section. the fan speed may be doubled through bit 3 of fan control register at 0x58.
smsc ds ? LPC47M15X page 162 rev. 08/02/2001 name reg offset (hex) description fan control default = 0x50 on vtr por 58 (r/w) fan control register bit[0] fan 1 clock source select this bit and the fan 1 clock multiplier bit is used with the fan 1 clock select bit in the fan 1 regi ster (0x56) to determine the fan speed f out . see table 56 in ?fan speed control and monitoring? section. bit[1] fan 2 clock source select this bit and the fan 2 clock multiplier bit is used with the fan 2 clock select bit in the fan 2 regi ster (0x57) to determine the fan speed f out . see table 56 in ?fan speed control and monitoring? section. bit[2] fan 1 clock multiplier 0=no multiplier used 1=double the fan speed selected by bit 0 of this register and bit 7 of the fan1 register bit[3] fan 2 clock multiplier 0=no multiplier used 1=double the fan speed selected by bit 1 of this register and bit 7 of the fan2 register bit[5:4] the fan1 count divisor. clock scalar for adjusting the tachometer count. default = 2. 00: divisor = 1 01: divisor = 2 10: divisor = 4 11: divisor = 8 bit[7:6] the fan2 count divisor. clock scalar for adjusting the tachometer count. default = 2. 00: divisor = 1 01: divisor = 2 10: divisor = 4 11: divisor = 8 fan1 tachometer register default = 0x00 on vtr por 59 (r) fan tachometer register 1 bit]7:0] the 8-bit fan1 tachometer count. the number of counts of the internal clock per pulse of the fan. the count value is computed from equation 1. this value is the final (maximum) count of the previous pulse (latched). the value in this register may not be valid for up to 2 pulses following a write to the preload register. fan2 tachometer register default = 0x00 on vtr por 5a (r) fan tachometer register 2 bit[7:0] the 8-bit fan2 tachometer count. the number of counts of the internal clock per pulse of the fan. the count value is computed from equation 1. this value is the final (maximum) count of the previous pulse (latched). the value in this register may not be valid for up to 2 pulses following a write to the preload register. fan1 preload register default = 0x00 on vtr por 5b (r/w) fan preload register 1 bit[7:0] the fan1 tachometer preload. this is the initial value used in the computation of the fan1 count. writing this register resets the tachometer count. fan2 preload register default = 0x00 on vtr por 5c (r/w) fan preload register 2 bit[7:0] the fan2 tachometer preload. this is the initial value used in the computation of the fan2 count. writing this register resets the tachometer count.
smsc ds ? LPC47M15X page 163 rev. 08/02/2001 name reg offset (hex) description led1 default = 0x00 on vtr por 5d (r/w) led1 bit[1:0] led1 control 00=off 01=blink at 1hz rate with a 50% duty cycle (0.5 sec on, 0.5 sec off) 10=blink at ? hz rate with a 25% duty cycle (0.5 sec on, 1.5 sec off) 11=on bits[7:2] reserved led2 default = 0x00 on vtr por 5e (r/w) led2 bit[1:0] led2 control 00=off 01=blink at 1hz rate with a 50% duty cycle (0.5 sec on, 0.5 sec off) 10=blink at ? hz rate with a 25% duty cycle (0.5 sec on, 1.5 sec off) 11=on bits[7:2] reserved keyboard scan code default = 0x00 on vtr por 5f (r/w) keyboard scan code bit[0] lsb of scan code . . . . . . . . . bit[7] msb of scan code n/a 60-7f (r) bits[7:0] reserved ? reads return 0 user note: when selecting an alternate function for a gpio pin, all bits in the gpio register must be properly programmed, including in/out, polarity and output type. the polarity bit does not affect the ddrc function or the either edge triggered interrupt functions. user note 1: if this pin is used for ring indicator wakeup, ei ther the nri2 event can be enabled via bit 1 in the pme_en1 register or the gp50 pme event can be enabled via bit 0 in the pme_en5 register. user note 2: in order to use the p12, p16 and p17 functions, the corresponding gpio must be programmed for output, non-invert, and push-pull output type. note 1: if the eeti function is selected for this gpio then bot h a high-to-low and a low-to-high edge will set the pme, smi and msc status bits. note 2: the irtx2 function can be used on this pi n if the ir location mux bit in the se rial port 2 ir option register is set. note 3: these pins default to an output and low on vcc por and hard reset. note 4: if the fdc function is selected on this pin (nmtr1, nds1, drvden0, drvden1) then bit 6 of the fdd mode register (configuration register 0xf0 in logical device 0) will override bit 7 in the gpio control register. bit 7 of the fdd mode register will also affect the pin if the fdc function is selected. note 5: the nio_smi pin is inactive when the internal gr oup smi signal is inactive and when the smi enable bit (en_smi, bit 7 of the smi_en2 register) is ?0?. when the output buffer type is od, nio_smi pin is floating when inactive; when the output buffer type is push- pull, the nio_smi pin is high when inactive. note 6: bits 2 and 3 of the pme_sts4 and smi_sts4 registers, and bit 3 of the pme_sts5 register may be set on a vcc por. if gp32, gp33 and gp53 are configured as input, then their co rresponding pme and smi status bits will be set on a vcc por. these gpios cannot be us ed for pme wakeup when the part is under vtr power (vcc=0). note 7: these bits are r/w but have no effect on circuit operation.
smsc ds ? LPC47M15X page 164 rev. 08/02/2001 8. configuration the configuration of the LPC47M15X is very flexible and is based on the configuration architecture implemented in typical plug-and-play components. the LPC47M15X is desi gned for motherboard applications in which the resources required by their components are known. with its flexible resource allocation architecture, the LPC47M15X allows the bios to assign resources at post. system elements primary configuration address decoder after a hard reset (npci_reset pin asserted) or vcc powe r on reset the LPC47M15X is in the run mode with all logical devices disabled. the logical devices may be conf igured through two standard configuration i/o ports (index and data) by placing the lp c47m15x into configuration mode. the bios uses these configuration port s to initialize the logical devices at post. the index and data ports are only valid when the LPC47M15X is in configuration mode. the sysopt pin is latched on the fall ing edge of the npci_reset or on vcc power on reset to determine the configuration register?s base address. the sysopt pin is used to select t he config port?s i/o address at power- up. once powered up the configurati on port base address can be changed th rough configuration registers cr26 and cr27. the sysopt pin is a hardware configuration pin which is shared with the gp24 signal on pin 45. note : an external pull-down resistor is required for the base io address to be 0x02e for configuration. an external pull-up resistor is required to move the base io address for configuration to 0x04e. the index and data ports are effective only w hen the chip is in t he configuration state. port name sysopt= 0 10k pull-down resistor sysopt= 1 10k pull-up resistor type config port (note) 0x02e 0x04e write index port (note) 0x02e 0x04e read/write data port index port + 1 read/write note: the configuration port base addre ss can be relocated through cr26 and cr27. entering the configuration state the device enters the configur ation state when the following config key is successfully written to the config port. config key = <0x55> exiting the configuration state the device exits the configurat ion state when the following config key is successfully written to the config port. config key = <0xaa> configuration sequence to program the configuratio n registers, the following sequence must be followed: 1) enter configuration mode 2) configure the configuration registers 3) exit configuration mode enter configuration mode to place the chip into the configuratio n state the config key is sent to t he chip?s config port. the config key consists of 0x55 written to the config port. once the c onfiguration key is received co rrectly the chip enters into the configuration state (the auto config ports are enabled).
smsc ds ? LPC47M15X page 165 rev. 08/02/2001 configuration mode the system sets the logical device information and activates desired logical devices through the index and data ports. in configuration mode, the inde x port is located at the config po rt address and the data port is at index port address + 1. the desired configuration register s are accessed in two steps: a) write the index of the logical de vice number configuration register (i.e., 0x07) to the index port and then write the number of the desired logical device to the data port b) write the address of the desired conf iguration register within the logical device to the index port and then write or read the configuration r egister through the data port. note: if accessing the global configuration registers, step (a) is not required. exit configuration mode to exit the configuration st ate the system writes 0xaa to the config po rt. the chip returns to the run state. note: only two states are defined (run and configuration). in the run state the chip will always be ready to enter the configurat ion state. programming example the following is an example of a configuration program in intel 8086 assembly language. ;----------------------------. ; enter configuration mode | ;----------------------------? mov dx,02eh mov ax,055h out dx,al ;----------------------------. ; configure register cre0, | ; logical device 8 | ;----------------------------? mov dx,02eh mov al,07h out dx,al ;point to ld# config reg mov dx,02fh mov al, 08h out dx,al;point to logical device 8 ; mov dx,02eh mov al,e0h out dx,al ; point to cre0 mov dx,02fh mov al,02h out dx,al ; update cre0 ;-----------------------------. ; exit configuration mode | ;-----------------------------? mov dx,02eh mov ax,0aah out dx,al notes: hard reset: npci_reset pin asserted soft reset: bit 0 of configurati on control register set to one all host accesses are blocked for 500s after vcc por (see power-up timing diagram)
smsc ds ? LPC47M15X page 166 rev. 08/02/2001 table 64 ? LPC47M15X configuration registers summary index type hard reset vcc por vtr por soft reset configuration register global configuration registers 0x02 w 0x00 0x00 0x00 - config control 0x03 r - - - - reserved ? reads return 0 0x07 r/w 0x00 0x00 0x00 0x00 logical device number 0x20 r 0x60 0x60 0x60 0x60 device id - hard wired 0x21 r current revision device rev - hard wired 0x22 r/w 0x00 0x00 0x00 0x00 power control 0x23 r/w 0x00 0x00 0x00 - power mgmt 0x24 r/w 0x44 0x44 0x44 - osc 0x26 r/w sysopt=0: 0x2e sysopt=1: 0x4e sysopt=0: 0x2e sysopt=1: 0x4e - - configuration port address byte 0 (low byte) 0x27 r/w sysopt=0: 0x00 sysopt=1: 0x00 sysopt=0: 0x00 sysopt=1: 0x00 - - configuration port address byte 1 (high byte) 0x28 r - - - - reserved 0x2a r/w - 0x00 0x00 - test 6 0x2b r/w - 0x00 0x00 - test 4 0x2c r/w - 0x00 0x00 - test 5 0x2d r/w - 0x00 0x00 - test 1 0x2e r/w - 0x00 0x00 - test 2 0x2f r/w - 0x00 0x00 - test 3 logical device 0 configuration registers (fdd) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, 0x61 r/w 0x03, 0xf0 0x03, 0xf0 0x03, 0xf0 0x03, 0xf0 primary base i/o address 0x70 r/w 0x06 0x06 0x06 0x 06 primary interrupt select 0x74 r/w 0x02 0x02 0x02 0x02 dma channel select 0xf0 r/w 0x0e 0x0e 0x0e - fdd mode register 0xf1 r/w 0x00 0x00 0x00 - fdd option register 0xf2 r/w 0xff 0xff 0xff - fdd type register 0xf4 r/w 0x00 0x00 0x00 - fdd0 0xf5 r/w 0x00 0x00 0x00 - fdd1 logical device 1 configuration registers (reserved) logical device 2 configuration registers (reserved) logical device 3 configuration registers (parallel port) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, 0x61 r/w 0x00, 0x00 0x00, 0x00 0x00, 0x00 0x00, 0x00 primary base i/o address 0x70 r/w 0x00 0x00 0x00 0x 00 primary interrupt select 0x74 r/w 0x04 0x04 0x04 0x04 dma channel select 0xf0 r/w 0x3c 0x3c 0x3c - parallel port mode register 0xf1 r/w 0x00 0x00 0x00 - parallel port mode register 2 logical device 4 configuration registers (serial port 1) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, 0x61 r/w 0x00, 0x00 0x00, 0x00 0x00, 0x00 0x00, 0x00 primary base i/o address
smsc ds ? LPC47M15X page 167 rev. 08/02/2001 index type hard reset vcc por vtr por soft reset configuration register 0x70 r/w 0x00 0x00 0x00 0x 00 primary interrupt select 0xf0 r/w 0x00 0x00 0x00 - serial port 1 mode register logical device 5 configuration registers (serial port 2) 0x30 r/w - - 0x00 - activate 0x60, 0x61 r/w 0x00, 0x00 0x00, 0x00 0x00, 0x00 0x00, 0x00 primary base i/o address 0x62, 0x63 r - - - - reserved ? reads return 0 0x70 r/w 0x00 0x00 0x00 0x 00 primary interrupt select 0x74 r - - - - reserved ? reads return 0 0xf0 r/w 0x00 0x00 0x00 - serial port 2 mode register 0xf1 r/w 0x02 0x02 0x02 - ir options register 0xf2 r/w 0x03 0x03 0x03 - ir half duplex timeout logical device 6 configuration registers (reserved) logical device 7 configuration registers (keyboard) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x70 r/w 0x00 0x00 0x00 0x00 primary interrupt select (keyboard) 0x72 r/w 0x00 0x00 0x00 0x00 secondary interrupt select (mouse) 0xf0 r/w 0x00 (note 1) 0x00 (note 1) 0x00 - kreset and gatea20 select logical device 8 configuration registers (reserved) logical device 9 configuration registers (game port) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, 0x61 r/w 0x00, 0x00 0x00, 0x00 0x00, 0x00 0x00, 0x00 primary base i/o address, game_port logical device a configuration registers (runti me registers) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, 0x61 r/w 0x00, 0x00 0x00, 0x00 0x00, 0x00 0x00, 0x00 primary base i/o address 0xf0 r/w - - 0x00 - clocki32 0xf1 r - - - - reserved logical device b configur ation registers (mpu-401) 0x30 r/w 0x00 0x00 0x00 0x00 activate 0x60, r/w 0x03 0x03 0x03 0x03 mpu-401 primary base i/o address high byte 0x61 r/w 0x30 0x30 0x30 0x30 mpu-401 primary base i/o address low byte 0x70 r/w 0x05 0x05 0x05 0x 05 primary interrupt select 0xf0 r - - - - reserved note: reserved registers are read-only, reads return 0. note 1. bits[6:5] of this r egister reset on vtr por only. chip level (global) control/configuration registers[0x00-0x2f] the chip-level (global) registers lie in the address rang e [0x00-0x2f]. the design must use all 8 bits of the address port for register selection. all unimplemented regi sters and bits ignore writes and return zero when read. the index port is used to select a conf iguration register in the chip. the data port is then used to access the selected register. these registers are a ccessible only in the configuration mode.
smsc ds ? LPC47M15X page 168 rev. 08/02/2001 table 65 ? chip level registers register address description chip (global) control registers 0x00 - 0x01 reserved - writes are ignored, reads return 0. config control default = 0x00 on vcc por, vtr por and hard reset 0x02 w the hardware automatically clears this bit after the write, there is no need for software to clear the bits. bit 0 = 1: soft reset. re fer to the ?configuration registers? table for the soft reset value for each register. 0x03 - 0x06 reserved - writes are ignored, reads return 0 . logical device # default = 0x00 on vcc por, vtr por, soft reset and hard reset 0x07 r/w a write to this register selects the current logical device. this allows access to the control and configuration registers fo r each logical device. note: the activate command operates only on the selected logical device. card level reserved 0x08 - 0x1f reserved - writes are ignored, reads return 0 . chip level, smsc defined device id - hard wired default = 0x60 on vcc por, vtr por, soft reset and hard reset 0x20 r a read only register which provides device identification. bits[7:0] = 0x 60 when read. device rev hard wired = current revision 0x21 r a read only register which provides device revision information. bits[7:0] = current revision when read. powercontrol default = 0x00 on vcc por, vtr por, soft reset and hard reset 0x22 r/w bit[0] fdc power bit[1] reserved bit[2] game port power bit[3] parallel port power bit[4] serial port 1 power bit[5] serial port 2 power bit[6] mpu-401 power bit[7] reserved 0: power off or disabled 1: power on or enabled
smsc ds ? LPC47M15X page 169 rev. 08/02/2001 register address description power mgmt default = 0x00 on vcc por, vtr por and hard reset 0x23 r/w bit[0] fdc (see note in the ?fdc power management? section) bit[1] reserved bit[2] reserved bit[3] parallel port bit[4] serial port 1 bit[5] serial port 2 bit[6] mpu-401 bit[7] reserved (read as 0) for each bit above (except reserved) = 0 intelligent pwr mgmt off = 1 intelligent pwr mgmt on osc default = 0x44, on on vcc por, vtr por and hard reset 0x24 r/w bit[0] reserved bit [1] pll control = 0 pll is on (backward compatible) = 1 pll is off bits[3:2] osc = 01 osc is on, brg clock is on. = 10 same as above (01) case. = 00 osc is on, brg clock enabled. = 11 osc is off, brg cl ock is disabled. bit [5:4] reserved, set to zero bit [6] 16-bit address qualification = 0 12-bit address qualification = 1 16-bit address qualification note : for normal operation, bit 6 should be set. bit[7] reserved chip level vendor defined 0x25 reserved - writes are ignored, reads return 0. configuration address byte 0 default =0x2e (sysopt=0) =0x4e (sysopt=1) on vcc por and hard reset 0x26 bit[7:1] configuration address bits [7:1] bit[0] = 0 see note 1 configuration address byte 1 default = 0x00 on vcc por and hard reset 0x27 bit[7:0] configuration address bits [15:8] see note 1 default = 0x00 on vcc por, soft reset and hard reset 0x28 bits[7:0] reserved - writes are ignored, reads return 0. chip level vendor defined 0x29 reserved - writes are ignored, reads return 0.
smsc ds ? LPC47M15X page 170 rev. 08/02/2001 register address description test 6 default = 0x00, on vcc por and vtr por 0x2a r/w test modes: reserved for smsc. users should not write to this register, may produce undesired results. test 4 default = 0x00, on vcc por and vtr por 0x2b r/w test modes: reserved for smsc. users should not write to this register, may produce undesired results. test 5 default = 0x00, on vcc por and vtr por 0x2c r/w bit[7] test mode: reserved for smsc. users should not write to this bit, may produce undesired results. bit[6] 8042 reset: 1 = put the 8042 into reset 0 = take the 8042 out of reset bits[5:0] test mode: reserved for smsc. users should not write to this bit, may produce undesired results. test 1 default = 0x00, on vcc por and vtr por 0x2d r/w test modes: reserved for smsc. users should not write to this register, may produce undesired results. test 2 default = 0x00, on vcc por and vtr por 0x2e r/w test modes: reserved for smsc. users should not write to this register, may produce undesired results. test 3 default = 0x00, on vcc por and vtr por 0x2f r/w test modes: reserved for smsc. users should not write to this register, may produce undesired results. note 1: to allow the selection of the configuration address to a user defined location, these configuration address bytes are used. there is no restriction on the address chosen, except that a0 is 0, that is, the address must be on an even byte boundary. as soon as both bytes are changed, the configuration space is moved to the specified location with no delay ( note: write byte 0, then byte 1; writing cr27 changes the base address). the configuration address is only reset to its default address upon a hard reset or vcc por. note: the default configuration address is either 02 eh or 04eh, as specified by the sysopt pin.
smsc ds ? LPC47M15X page 171 rev. 08/02/2001 logical device configuration/control registers [0x30-0xff] used to access the registers that are assigned to each logical unit. this chip supports eight logical units and has eight sets of logical device registers. the eight logical devices are floppy, parallel, serial 1, serial 2, keyboard controller, game port, runtime registers and mpu-401. a separate set (bank) of control and configuration registers exists for each logical device and is selected with the logical device # register (0x07). the index port is used to select a specific logical devic e register. these registers are then accessed through the data port. the logical device registers are accessible only when the dev ice is in the configuration state. the logical register addresses are shown in the table below. table 66 ? logical device registers logical device register address description activate (note1) default = 0x00 on vcc por, vtr por, hard reset and soft reset (0x30) bits[7:1] reserved, set to zero. bit[0] = 1 activates the logical device currently selected through the logical device # register. = 0 logical device currently selected is inactive logical device control (0x31-0x37) reserved ? writes are ignored, reads return 0. logical device control (0x38-0x3f) vendor defined - reserved - writes are ignored, reads return 0. memory base address (0x40-0x5f) reserved ? writes are ignored, reads return 0. i/o base address (note 2) (see device base i/o address table) default = 0x00 on vcc por, vtr por, hard reset and soft reset (0x60-0x6f) 0x60,2,... = addr[15:8] 0x61,3,... = addr[7:0] registers 0x60 and 0x61 set the base address for the device. if more than one base address is required, the second base address is set by registers 0x62 and 0x63. refer to table 67 for the number of base address registers used by each device. unused registers will ignore writes and return zero when read. interrupt select defaults : 0x70 = 0x00 or 0x06 (note 3) on vcc por, vtr por, hard reset and soft reset 0x72 = 0x00, on vcc por, vtr por, hard reset and soft reset (0x70,0x72) 0x70 is implemented for each logical device. refer to interrupt configuration register description. only the keyboard controller uses interrupt select register 0x72. unused register (0x72) will ignore writes and return zero when read. interrupts default to edge high (isa compatible). (0x71,0x73) reserved - not implemented. these register locations ignore writes and return zero when read.
smsc ds ? LPC47M15X page 172 rev. 08/02/2001 logical device register address description dma channel select default = 0x02 or 0x04 (note 4) on vcc por, vtr por, hard reset and soft reset (0x74,0x75) only 0x74 is implemented for fdc and parallel port. 0x75 is not implemented and ignores writes and returns zero when read. refer to dma channel configuration. 32-bit memory space configuration (0x76-0xa8) reserved - not implemented. these register locations ignore writes and return zero when read. logical device (0xa9-0xdf) reserved - not implemented. these register locations ignore writes and return zero when read. logical device configuration (0xe0-0xfe) reserved ? vendor defined (see smsc defined logical device configuration registers). reserved 0xff reserved note 1: a logical device will be active and powered up according to the following equation unless otherwise specified: device on (active) = (activate bit set or pwr/control bit set). the logical device?s activate bit and its pwr/control bit are linked such that setting or clearing one sets or clears the other. note 2: if the i/o base addr of the logical device is not within the base i/o range as shown in the logical device i/o map, then read or write is not valid and is ignored. note 3: the default value of the primary interrupt se lect register for logical device 0 is 0x06. note 4: the default value of the dma channel select register for logical device 0 (fdd) is 0x02 and for logical device 3 and 5 is 0x04.
smsc ds ? LPC47M15X page 173 rev. 08/02/2001 table 67 ? i/o base address configuration register description logical device number logical device register index base i/o range (note 1) fixed base offsets 0x00 fdc 0x60,0x61 [0x0100:0x0ff8] on 8 byte boundaries +0 : sra +1 : srb +2 : dor +3 : tdr +4 : msr/dsr +5 : fifo +7 : dir/ccr 0x01 reserved n/a n/a n/a 0x02 reserved n/a n/a n/a [0x0100:0x0ffc] on 4 byte boundaries (epp not supported) or [0x0100:0x0ff8] on 8 byte boundaries +0 : data/ecpafifo +1 : status +2 : control +400h : cfifo/ecpdfifo/tfifo/cnfga +401h : cnfgb +402h : ecr 0x03 parallel port 0x60,0x61 (all modes supported, epp is only available when the base address is on an 8- byte boundary) +3 : epp address +4 : epp data 0 +5 : epp data 1 +6 : epp data 2 +7 : epp data 3 0x04 serial port 1 0x60,0x61 [0x0100:0x0ff8] on 8 byte boundaries +0 : rb/tb/lsb div +1 : ier/msb div +2 : iir/fcr +3 : lcr +4 : msr +5 : lsr +6 : msr +7 : scr 0x05 serial port 2 0x60,0x61 [0x0100:0x0ff8] on 8 byte boundaries +0 : rb/tb/lsb div +1 : ier/msb div +2 : iir/fcr +3 : lcr +4 : msr +5 : lsr +6 : msr +7 : scr 0x06 reserved n/a n/a n/a 0x07 kybd n/a not relocatable fixed base address: 60,64 +0 : data register +4 : command/status reg. 0x08 reserved n/a n/a n/a 0x09 game port 0x60,0x61 [0x0100:0x0fff] on 1 byte boundaries +00: game port register
smsc ds ? LPC47M15X page 174 rev. 08/02/2001 table 67 ? i/o base address configuration register description logical device number logical device register index base i/o range (note 1) fixed base offsets 0x0a runtime register block 0x60,0x61 [0x0000:0x0f7f] on 128-byte boundaries +00 : pme status . . . +5f : keyboard scan code (see table in ?runtime registers? section for full list) 0x0b mpu-401 0x60,0x61 [0x0100:0x0ffe] on 2-byte boundaries +0: midi data +1: status/command config. port config. port 0x26, 0x27 (note 2) 0x0100:0x0ffe on 2 byte boundaries see configuration register in table 64. accessed through the index and data ports located at the configuration port address and the configuration port address +1 respectively. note 1: this chip uses address bits [a11:a0] to decode the base address of each of its logical devices. bit 6 of the osc global configuration register (cr24) must be set to ?1? and address bits [a15:a12] must be ?0? for 16 bit address qualification. note 2: the configuration port is at either 0x02e or 0x04e (for sysopt=0 or sysopt=1) at power up and can be relocated via the global configuration registers at 0x26 and 0x27. table 68 ? interrupt select configuration register description name reg index definition primary interrupt select default=0x00 or 0x06 (note 1) on vcc por, vtr por, hard reset and soft reset 0x70 (r/w) bits[3:0] selects which interrupt is used for the primary interrupt. 0x00= no interrupt selected 0x01= irq1 0x02= irq2/nsmi 0x03= irq3 0x04= irq4 0x05= irq5 0x06= irq6 0x07= irq7 0x08= irq8 0x09= irq9 0x0a= irq10 0x0b= irq11 0x0c= irq12 0x0d= irq13 0x0e= irq14 0x0f= irq15 note: all interrupts are edge high (except ecp/epp) note: nsmi is active low note: an interrupt is activated by setting the interrupt request level select 0 register to a non-zero value and: for the fdc logical device by setting dmaen, bit d3 of the digital output register. for the pp logical device by setting irqe, bit d4 of the control port and in addition for the pp logical device in ecp mode by clearing serviceintr, bit d2 of the ecr. for the serial port logical device by setting any combination of bits d0-d3 in the ier and by setting the out2 bit in the uart's modem control (mcr) register. for the kybd logical device (refer to the kybd controller section of this spec). for mpu-401 logical device (refer to the mpu-401 section of this spec). note: irqs are disabled if not used/selected by any logical device. refer to note a. note: nsmi must be disabled to use irq2.
smsc ds ? LPC47M15X page 175 rev. 08/02/2001 note: all irq?s are available in serial irq mode. note 1: the default value of the primary interrupt se lect register for logical device 0 is 0x06. table 69 ? dma channel select configuration register description name reg index definition dma channel select default=0x02 or 0x04 (note 1) on vcc por, vtr por, hard reset and soft reset 0x74 (r/w) bits[2:0] select the dma channel. 0x00= reserved 0x01= dma1 0x02= dma2 0x03= dma3 0x04-0x07= no dma active note: a dma channel is activated by setting the dma channel select register to [0x01-0x03] and : for the fdc logical device by setting dmaen, bit d3 of the digital output register. for the pp logical device in ecp mode by setting dmaen, bit d3 of the ecr. note: the dma channel must be disabled if not used/selected by any logical device. refer to note a. note 1: the default value of the dma channel select register for logical device 0 (fdd) is 0x02 and for logical device 3 is 0x04. note a. logical device irq and dma operation 1) irq and dma enable and disable: any time the irq or dma channel for a logical block is disabled by a register bit in that logical block, the irq and/or dma channel must be disabled. this is in addition to the irq and dma channel disabled by the configuration registers (active bit or address not valid). a) fdc: for the following cases, the irq and dma channel used by the fdc are disabled. digital output register (base+2) bit d3 (dmaen) set to ?0?. the fdc is in power down (disabled). b) serial ports: modem control register (mcr) bit d2 (out2) - when out2 is a logic ?0?, the serial port interrupt is disabled. c) parallel port: i. spp and epp modes: control port (base+2) bit d4 (irqe) set to ?0?, irq is disabled. ii. ecp mode: (1) (dma) dmaen from ecr register. see table. (2) irq - see table. mode (from ecr register) irq controlled by dma controlled by 000 printer irqe dmaen 001 spp irqe dmaen 010 fifo (on) dmaen 011 ecp (on) dmaen 100 epp irqe dmaen 101 res irqe dmaen 110 test (on) dmaen 111 config irqe dmaen d) keyboard controller: refer to the kbd section of this spec. e) mpu-401: refer to the mpu-401 section of this spec.
smsc ds ? LPC47M15X page 176 rev. 08/02/2001 smsc defined logical device configuration registers the smsc specific logical device config uration registers reset to their default values only on hard resets generated by vcc or vtr por (as shown) or th e npci_reset signal. these registers are not affected by soft resets. table 70 ? floppy disk controller, logical device 0 [logical device number = 0x00] name reg index definition fdd mode register default = 0x0e on vcc por, vtr por and hard reset 0xf0 r/w bit[0] floppy mode = 0 normal floppy mode (default) = 1 enhanced floppy mode 2 (os2) bit[1] fdc dma mode = 0 burst mode is enabled = 1 non-burst mode (default) bit[3:2] interface mode = 11 at mode (default) = 10 (reserved) = 01 ps/2 = 00 model 30 bit[4] fdc_swap 0 = do not swap (default) 1 = swap drive 0 (nds, nmtr pins) with drive 1 (nds, nmtr pins) bit[5] reserved, set to zero bit[6] fdc output type control = 0 fdc outputs are od12 open drain (default) = 1 fdc outputs are o12 push-pull bit[7] fdc output control = 0 fdc outputs active (default) = 1 fdc outputs tri-stated fdd option register default = 0x00 on vcc por, vtr por and hard reset 0xf1 r/w bit[0] forced write protect = 0 inactive (default) = 1 fdd nwrtprt input is forced active when either of the drives has been selected. nwrtprt (to the fdc core) = wp (fdc sra register, bit 1) = (nds0 and forced write protect) or (nds1 and forced write protect) or nwrtprt (from the fdd interface) or floppy write protect note: the floppy write protect bit is in the device disable register. note: boot floppy is always drive 0. bit[1] reserved bits[3:2] density select = 00 normal (default) = 01 normal (reserved for users) = 10 1 (forced to logic ?1?) = 11 0 (forced to logic ?0?) bit[7:4] reserved. fdd type register default = 0xff on vcc por, vtr por and hard reset 0xf2 r/w bits[1:0] floppy drive a type bits[3:2] floppy drive b type bits[5:4] reserved (could be used to store floppy drive c type) bits[7:6] reserved (could be used to store floppy drive d type) note: the LPC47M15X supports two floppy drives 0xf3 r reserved, read as 0 (read only)
smsc ds ? LPC47M15X page 177 rev. 08/02/2001 name reg index definition fdd0 default = 0x00 on vcc por, vtr por and hard reset 0xf4 r/w bits[1:0] drive type select: dt1, dt0 bits[2] read as 0 (read only) bits[4:3] data rate table select: drt1, drt0 bits[5] read as 0 (read only) bits[6] precompensation disable pts =0 use precompensation =1 no precompensation bits[7] read as 0 (read only) fdd1 0xf5 r/w refer to definition and default for 0xf4 table 71 ? parallel port, logical device 3 [logical device number = 0x03] name reg index definition pp mode register default = 0x3c on vcc por, vtr por and hard reset 0xf0 r/w bits[2:0] parallel port mode = 100 printer mode (default) = 000 standard and bi-directional (spp) mode = 001 epp-1.9 and spp mode = 101 epp-1.7 and spp mode = 010 ecp mode = 011 ecp and epp-1.9 mode = 111 ecp and epp-1.7 mode bit[6:3] ecp fifo threshold 0111b (default) bit[7] pp interupt type not valid when the parallel port is in the printer mode (100) or the standard & bi-directional mode (000). = 1 pulsed low, released to high-z. = 0 irq follows nack when parallel port in epp mode or [printer,spp, epp] under ecp. irq level type when the parallel port is in ecp, test, or centronics fifo mode. pp mode register 2 default = 0x00 on vcc por, vtr por and hard reset 0xf1 r/w bits[3:0] reserved. set to zero bit [4] timeout_select = 0 tmout (epp status reg.) cleared on write of ?1? to tmout. = 1 tmout cleared on trailing edge of read of epp status reg. bits[7:5] reserved. set to zero.
smsc ds ? LPC47M15X page 178 rev. 08/02/2001 table 72 ? serial port 1, logical device 4 [logical device number = 0x04] name reg index definition serial port 1 mode register default = 0x00 on vcc por, vtr por and hard reset 0xf0 r/w bit[0] midi mode = 0 midi support disabled (default) = 1 midi support enabled bit[1] high speed = 0 high speed disabled(default) = 1 high speed enabled bit[6:2] reserved, set to zero bit[7]: share irq =0 uarts use different irqs =1 uarts share a common irq see note 1 below. note 1: to properly share and irq, 1. configure uart1 (or uart 2) to use the desired irq. 2. configure uart2 (or uart1) to use no irq selected. 3. set the share irq bit. note: if both uarts are configured to use different irqs and the share irq bit is set, then both of the uart irqs will assert when either uart generates an interrupt.
smsc ds ? LPC47M15X page 179 rev. 08/02/2001 uart interrupt operation table table 73 ? serial port 2, logical device 5 [logical device number = 0x05] name reg index definition serial port 2 mode register default = 0x00 on vcc por, vtr por and hard reset bit[5] reset on vtr por only 0xf0 r/w bit[0] midi mode = 0 midi support disabled (default) = 1 midi support enabled bit[1] high speed = 0 high speed disabled(default) = 1 high speed enabled bit[4:2] reserved, set to zero bit[5] txd2_mode (note 1) =0 the inactive state of the txd2 pin is low. =1 the inactive state of the txd2 pin is tristate. bits[7:6] reserved. set to zero. ir option register default = 0x02 on vcc por, vtr por and hard reset 0xf1 r/w bit[0] receive polarity = 0 active high (default) = 1 active low bit[1] transmit polarity = 0 active high = 1 active low (default) bit[2] duplex select = 0 full duplex (default) = 1 half duplex bits[5:3] ir mode = 000 standard com functionality (default) = 001 irda = 010 ask-ir = 011 reserved = 1xx reserved bit[6] ir location mux = 0 use serial port txd2 and rxd2 (default) = 1 use alternate irrx2 (pin 61) and irtx2 (pin 62). bit[7] reserved, write 0. ir half duplex timeout default = 0x03 on vcc por, vtr por and hard reset 0xf2 bits [7:0] these bits set the half duplex time-out for the ir port. this value is 0 to 10msec in 100usec increments. 0= blank during transmit/receive 1= blank during transmit/receive + 100usec note 1: the txd2_mode bit is a vtr powered bit that is reset on vtr por only.
smsc ds ? LPC47M15X page 180 rev. 08/02/2001 table 74 ? kybd, logical device 7 [logical device number = 0x07] name reg index definition krst_ga20 default = 0x00 on vcc por, vtr por and hard reset bits[6:5] reset on vtr por only 0xf0 r/w kreset and gatea20 select bit[7] polarity select for p12 = 0 p12 active low (default) = 1 p12 active high bit[6] m_iso. enables/disables isolation of mouse signals into 8042. does not affect mdat signal to mouse wakeup (pme) logic. 1=block mouse clock and data signals into 8042 0= do not block mouse clock and data signals into 8042 bit[5] k_iso. enables/disables isolation of keyboard signals into 8042. does not affect kdat signal to keyboard wakeup (pme) logic. 1=block keyboard clock and data signals into 8042 0= do not block keyboard clock and data signals into 8042 bit[4] mlatch = 0 mint is the 8042 mint anded with latched mint (default) = 1 mint is the latched 8042 mint bit[3] klatch = 0 kint is the 8042 kint anded with latched kint (default) = 1 kint is the latched 8042 kint bit[2] port 92 select = 0 port 92 disabled = 1 port 92 enabled bit[1] reserved bit[0] reserved
smsc ds ? LPC47M15X page 181 rev. 08/02/2001 table 75 ? pme, logical device a [logical device number = 0x0a] name reg index definition clocki32 default = 0x00 on vtr por 0xf0 (r/w) bit[0] (clk32_prsn) 0=32khz clock is connected to the clki32 pin (default) 1=32khz clock is not connected to the clki32 pin (pin is grounded) bit[1] spekey_en. this bit is used to turn the logic for the ?wake on specific key? feature on and off. it will disable the 32khz clock input to the logic when turned off. the logic will draw no power when disabled. 0= ?wake on specific key? logic is on (default) 1= ?wake on specific key? logic is off bits[7:2] are reserved note: the registers located in logica l device a are runtime registers. table 76 ? mpu-401 [logical device number = 0x0b] name reg index definition mpu-401 primary base i/o address high byte default = 0x03 on hard reset, soft reset, vcc por and vtr por 0x60 r/w bit[0] a8 bit[1] a9 bit[2] a10 bit[3] a11 bit[4] ?0? bit[5] ?0? bit[6] ?0? bit[7] ?0? mpu-401 primary base i/o address low byte default = 0x30 on hard reset, soft reset, vcc por and vtr por 0x61 r/w bit[0] ?0? bit[1] a1 bit[2] a2 bit[3] a3 bit[4] a4 bit[5] a5 bit[6] a6 bit[7] a7 note: bit[0] must be ?0?.
smsc ds ? LPC47M15X page 182 rev. 08/02/2001 9. registers for hardw are monitoring block the registers in the hardware monitor block may be accessed by writing the correct address to the 8-bit internal address register. 9.1 register summary register offset (hex) type default register - w - internal address register 15-3d r/w - value or limit registers 3e r 0x55 company id 3f r 0x20 stepping number and version 40 r/w 0x08 configuration register 41 r 0x00 interrupt status register 1 42 r 0x00 interrupt status register 2 47 r/w note 1 vid register 49 r note 2 vid 4 register 4a r/w 0x00 test mode register 4b r 0x00 error debug register 4c r/w 0x00 test digital value register 4f r/w 0x00 special function register 50-59 r/w - value or limit registers note 1: the default value on bits[7:4]=0000 and bits[3:0]=vid3 ? vid0 note 2: the default on bits[7:1]=1000000 and bit[0]=vid4 9.2 internal address register name type description internal address register w this register is used to access the registers (see the following sub-sections). it stores the address of the register being accessed.
smsc ds ? LPC47M15X page 183 rev. 08/02/2001 9.3 value or limit registers (15h-3dh) register offset (hex) type description default 15 read / write manufacturers test register (not implemented) na 1e read/write offset register 2 00h note 1 1f read/write offset register 1 00h note 2 20 read only +2.5v reading na 21 read only vccp reading na 22 read only +3.3v reading na 23 read only +5v reading na 24 read only +12v reading na 25 read only hvcc reading na 26 read only remote diode temperature reading 1 na 27 read only ambient temperature reading na 2b read / write +2.5v high limit note 3 2c read / write +2.5v low limit note 3 2d read / write +vccp high limit note 3 2e read / write +vccp low limit note 3 2f read / write +3.3v high limit note 3 30 read / write +3.3v low limit note 3 31 read / write +5v high limit note 3 32 read / write +5v low limit note 3 33 read / write +12v high limit note 3 34 read / write +12v low limit note 3 35 read / write hvcc high limit note 3 36 read / write hvcc sense low limit note 3 37 read / write remote temperature high limit 1 note 3 38 read / write remote temperature low limit 1 note 3 39 read / write ambient temperature high limit note 3 3a read / write ambient temperature low limit note 3 3e-4f read/write see the ?registers 3e-4f? subsection below - 50 read only +1.5v reading na 51 read only +1.8v reading na 52 read only remote diode temperature reading 2 na 53 read only reserved 0x00 54 read / write +1.5v high limit note 3 55 read / write +1.5v low limit note 3 56 read / write +1.8v high limit note 3 57 read / write +1.8v low limit note 3 58 read / write remote temperature high limit 2 note 3 59 read / write remote temperature low limit 2 note 3 note 1: this offset register only applies to the remote dio de temperature reading 2. th is register contains a 2's complement value which is added (or subtracted if the number is negative) to external temperature reading 2. the default value in the offset register is zero, so init ially zero is always added to the temperature reading. note 2: this offset register only applies to the remote dio de temperature reading 1. th is register contains a 2's complement value which is added (or su btracted if the number is negative) to either the internal or external temperature reading. the default value in the offset register is zero, so initially zero is always added to the temperature reading. the offset regist er is configured for the external temperature channel by default. it may be switched to the in ternal channel by setting bit 4 of the special function register to 1. note 3: the default values of the high and low limit r egisters should be written after power on reset.
smsc ds ? LPC47M15X page 184 rev. 08/02/2001 9.3.1.1 registers 3eh-4fh name/default register offset (hex) description company id default=0x55 on hvcc por and initialization 3e (r) bits[7:0] this location contains the identification number which will be used by software to determine analog voltage curves. stepping number and version default=0x20 on hvcc por and initialization 3f (r) bits[7:0] this location contains the stepping number of the part in the lower four bits of the register [3:0]. the upper four bits reflect the version number [7:4]. the hardware monitor block has a version number (bits[7:4]) of 0010. for the a0 stepping of hardware monitor block, this register will read 0010 0000. configuration default = 0x08 on hvcc por and initialization 40 (r/wc) bit[4] is self-clearing bit[0] start logic 1 enables startup of monitor block, logic 0 places the block in the low power mode selected by bit 0 of the special function register at 4fh. at startup, limit checking functions and scanning begins. note, all high and low limits should be set into the asic prior to turning on this bit. bits[3:1] reserved bit[4] reset setting this bit generates a minimum 20 ms low pulse on the reset pin, if the function is enabled. (see vid register). this bit is self-clearing. bit[5] +12/vid4 select selects whether pin 10 acts as a 12 volt analog input monitoring pin, or as a vid[4] input. this pin defaults to the 12 volt analog input. bit[6] reserved bit[7] initialization logic 1 restores powerup defaul t values to the configuration register and interrupt status r egisters. this bit automatically clears itself since the power on default is zero.
smsc ds ? LPC47M15X page 185 rev. 08/02/2001 name/default register offset (hex) description interrupt status register 1 default = 0x00 on hvcc por and initialization 41 (r) bit[0] +2.5v_error a one indicates a high or low limit has been reached or exceeded. bit[1] vccp_error a one indicates a high or low limit has been reached or exceeded. bit[2] +3.3v_error a one indicates a high or low limit has been reached or exceeded. bit[3] +5v_error a one indicates a high or low limit has been reached or exceeded. bit[4] ambient temp error a one indicates that a high or a low temperature limit has been reached or exceeded. bit[5] remote temp error 1 a one indicates that a high or a low temperature limit on the remote temperature limit has been reached or exceeded on d0+ and d0- pins. bit[6] remote temp error 2 a one indicates that a high or a low temperature limit on the remote temperature limit has been reached or exceeded on d1+ and d1- pins. bit[7] reserved interrupt status register 2 default = 0x00 on hvcc por and initialization 42 (r) bit[0] +12v_error a one indicates a high or low limit has been reached or exceeded. bit[1] hvcc_error a one indicates a high or low limit has been reached or exceeded. bit[2] +1.5v error a one indicates a high or low limit has been reached or exceeded. bit[3] +1.8v error a one indicates a high or low limit has been reached or exceeded. bits[5:4] reserved bit[6] remote diode fault 1 a one indicates either a short or open circuited fault on the remote thermal diode inputs (d0+ and d0-). the following faults are detected: open d0+, open d0-, short to hvcc on d0+, short to hvcc on d0-, short to ground on d0+, short to ground on d0-, d0+ and d0- shorted to each other. bit[7] remote diode fault 2 a one indicates either a short or open circuited fault on the remote thermal diode inputs (d1+ and d1-). the following faults are detected: open d1+, open d1-, short to hvcc on d1+, short to hvcc on d1-, short to ground on d+, short to ground on d1-, d1+ and d1- shorted to each other.
smsc ds ? LPC47M15X page 186 rev. 08/02/2001 name/default register offset (hex) description vid register default: bits[7:4]=0000 bits[3:0]=vid3- vid0 on hvcc por and initialization 47 bits[6:0] are read only; bit[7] is (r/w) bits[3:0] vid[3:0] the vid[3:0] inputs from pentium/ pro power supplies to indicate the operating voltage (e.g. 1.5v to 2.9v). bits[6:4] reserved bit[7] nreset enable 0= enables a0 pin for lowest order programmable bit of smbus address (default) 1= enables the nreset pin output function vid4 register default: bits[7]=1, bits[6:1]=0 bit[0]=vid4 on hvcc por and initialization 49 (r) bit[0] vid 4 vid 4 input (if selected). bits[6:1] reserved bit[7] reserved1 test mode register default = 0x00 on hvcc por and initialization 4a (r/w) bit[0] selects the adc test mode. the default for this bit is zero, which deactivates adc test mode. bit[1] selects the digital test mode. the default for this bit is zero, which deactivates digital test mode. bit[2] selects the external clock test mode. the default for this bit is zero, which deactivates external oscillator clock test mode. bit[3] selects either 8 or 1 averaging for the adc test mode. the default for this bit is zero, which sets the averaging to 8 for the adc test mode. a one in this bit selects no averaging. bit[4] selects the oscillator clock to be muxed out on the vid2 pin. the default for this bit is zero, which deactivates mux oscillator clock test mode. bits[7:5] are used by the analog block for test purposes. these three bits of register 4ah are muxed out on pins dig_test_an_pad[2:0]. these bits are also used to mux out either the sda line or the sclk line to the vid3 pin. if bits[7:5] are ?001?, then the sda line is muxed out onto the vid3 pin. if bits[7:5] are ?010?, then the sclk line is muxed out onto the vid3 pin. error debug register default = 0x00 on hvcc por and initialization 4b (r) bit[0] indicates that no nack was generated by the host during either a read byte protocol or a receive byte protocol. bit[1] indicates a read or a write was attempted to an invalid register location. bit[2] indicates a write to a re ad only register was attempted bit[3] indicates a receive byte protocol was attempted when the address pointer register pointed to the 00h location. this is the default register location on power on reset. as noted in the ?bus protocols? section of the ?hardwar e monitoring interface? section, the internal address register should be set up with a valid address location by either a send byte protocol or a write byte protocol after power-on-reset, before the receive byte protocol. bit[4] indicates an invalid slave address was detected. bit[5] indicates a premature stop was detected. bit[6] indicates an error was detec ted during the smbus receive byte protocol response to an ara. bit[7] is reserved.
smsc ds ? LPC47M15X page 187 rev. 08/02/2001 name/default register offset (hex) description test digital value register default = 0x00 on hvcc por and initialization 4c (r/w) this register is used for the digital test mode test. special function register default = 0x00 on hvcc por and initialization 4f (r/w) bit[0] low-power mode select 0= sleep mode (default) 1= shutdown mode bit[1] monitoring mode select 0= continuous monitor mode (default) 1= cycle monitor mode bit[2] ntherm enable 0=a0/reset function as selected by bit 7 of vid register (default) 1=enables ntherm pin output function bit[3] ntherm voltage enable 0=out-of-limit/equal-limit voltages do not affect the state of the ntherm pin (default) 1=enable out-of-limit/equal-limit voltages to make the ntherm pin active low bit [4] offset register configure 0= offset register configured to the external temperature channels. (default) 1= offset register configured to the internal temperature channel. bit[5] number of measurements of each temperature and voltage reading made. 0= take 128 separate measurement s of the data from the analog block for both remote diode temperature readings before averaging the result and storing it in the value register for remote diode temperature measurements; take 8 separate measurements of all other voltage and intern al temperature readings before averaging. (default) 1 =use 16 averaging for both remote diode temperature readings and no averaging for all other voltage and internal temperature values. setting this bit to ?1? would be used for power saving. bits[7:6] reserved note: reserved bits are read-only and return ?0? when read. reserved1 bits are read-only and return a ?1? when read.
smsc ds ? LPC47M15X page 188 rev. 08/02/2001 10. operational description 10.1 maximum guaranteed ratings operating temper ature range .................................................................................................... ............... 0 o c to +70 o c storage temperat ure ra nge ...................................................................................................... ............. -55 o to +150 o c lead temperature range ......................................................................................... refer to jedec spec. j-std-020 note: stresses above those listed above and below could cause permanent damage to the device. this is a stress rating only and functional operation of the device at any other condition above those indicated in the operation sections of this specification is not implied. when powering this devi ce from laboratory or system power supplies, it is important that the absolute maximum ratings not be exceeded or device failure can result. some power supplies exhibit voltage spikes on their outputs when the ac power is switched on or off. in addition, voltage transients on the ac power line may appear on the dc output. if this possibility exists, it is suggested that a clamp circuit be used. 10.1.1 super i/o section (pins 1 to 100) maximum v cc ............................................................................................................................... ........................... +5.5v positive voltage on any pin, with respec t to ground ............................................................................ ..............v cc +0.3v negative voltage on any pin, with respec t to ground ............................................................................ ................. -0.3v 10.1.2 hardware monitoring block (pins 101 to 128) positive supply voltage (v+) +5.5 v (max) voltage on any input or output pin (hvcc-0.3v) to (hvcc+0.3v) (except analog inputs) maximum junction temperature (tjmax) 125 c 10.2 hardware monitoring block specifications 10.2.1 key specifications supply voltage hvcc-10% < hvcc < hvcc+10% voltage monitoring accuracy 2% (max) temperature accuracy see dc characteristics adc resolution 8 bits 10.2.2 supply current monitoring mode 1.2 ma (typical) 2 ma (max) sleep mode 200 a (typical) 500 a (max) shutdown mode 1 a (typical) 3 a (max) 10.2.3 operating temperature operating temperature range 0 c <= t a <= +70 c 10.2.4 operating voltage ratings 3.3 volt supply supply voltage (v+) +3 v to +3.6 v vin voltage range (digital pins) -0.05 v to 3.6v
smsc ds ? LPC47M15X page 189 rev. 08/02/2001 10.3 dc electrical characteristics super i/o block (t a = 0 o c ? 70 o c, v cc = +3.3 v 10%) parameter symbol min typ max units comments i type input buffer low input level high input level v ili v ihi 2.0 0.8 5.5 v v ttl levels is type input buffer low input level high input level schmitt trigger hysteresis v ilis v ihis v hys 2.2 100 0.8 5.5 v v mv schmitt trigger schmitt trigger o6 type buffer low output level high output level v ol v oh 2.4 0.4 v v i ol = 6ma i oh = -3ma o8 type buffer low output level high output level v ol v oh 2.4 0.4 v v i ol = 8ma i oh = -4ma od8 type buffer low output level high output level v ol v oh 0.4 vcc+0.3 v v i ol = 8ma open drain; vcc=3.3v o12 type buffer low output level high output level v ol v oh 2.4 0.4 v v i ol = 12ma i oh = -6ma od12 type buffer low output level high output level v ol v oh 0.4 vcc+0.3 v v i ol = 12ma open drain; vcc=3.3v od14 type buffer low output level high output level v ol v oh 0.4 vcc+0.3 v v i ol = 14ma open drain; vcc=3.3v op14 type buffer low output level high output level v ol v oh 2.4 0.4 v v i ol = 14ma i oh = -14ma
smsc ds ? LPC47M15X page 190 rev. 08/02/2001 super i/o block (t a = 0 o c ? 70 o c, v cc = +3.3 v 10%) parameter symbol min typ max units comments io8 type buffer low input level high input level low output level high output level v ili v ihi v ol v oh 2.0 2.4 0.8 5.5 0.4 v v v v ttl levels i ol = 8ma i oh = -4ma is/o8 type buffer low input level high input level schmitt trigger hysteresis low output level high output level v ili v ihi v hys v ol v oh 2.2 2.4 100 0.8 5.5 0.4 v v mv v v schmitt trigger schmitt trigger i ol = 8ma i oh = -4ma io12 type buffer low input level high input level low output level high output level v ili v ihi v ol v oh 2.0 2.4 0.8 5.5 0.4 v v v v ttl levels i ol = 12ma i oh = -6ma iop14 type buffer low input level high input level low output level high output level v ili v ihi v ol v oh 2.0 2.4 0.8 5.5 0.4 v v v v ttl levels i ol = 14ma i oh = -14ma iod16 type buffer low input level high input level low output level high output level v ili v ihi v ol v oh 2.0 0.8 5.5 0.4 vcc+0.3 v v v v ttl levels i ol = 16ma open drain; vcc=3.3v pci type buffers (pci_iclk, pci_i, pci_o, pci_io) 3.3v pci 2.1 compatible.
smsc ds ? LPC47M15X page 191 rev. 08/02/2001 super i/o block (t a = 0 o c ? 70 o c, v cc = +3.3 v 10%) parameter symbol min typ max units comments leakage current (all) input high current input low current ileak ih ileak il 10 -10 a a (note 1) v in = v cc v in = 0v backdrive protect/chiprotect (all signal pins excluding lad[3:0], nldrq, nlpcpd, nlframe) input high current input low current ileak ih ileak il 10 -10 a a v cc = 0v v in = 5.5v max v in = 0v 5v tolerant pins (all signal pins excluding lad[3:0], nldrq, nlpcpd, nlframe) inputs and outputs in high impedance state input high current input low current ileak ih ileak il 10 -10 a a v cc = 0v v in = 5.5v max v in = 0v lpc bus pins (lad[3:0], nldrq, nlpcpd, nlframe) input high current input low current ileak ih ileak il 10 -10 a a v cc = 0v and v cc = 3.3v v in = 3.6v max v in = 0v v cc supply current active i cc 15 ma all outputs open, all inputs transitioning from/to 0v or to/from 3.3v. trickle supply voltage v tr v cc min -.5v (note 2) v cc max v v cc must not be greater than .5v above v tr v tr supply current active i tr 0.25 (note 3) 5 (note 3) ma all outputs, all inputs transitioning from/to i.e., 0v to/from 3.3v). reference voltage v ref 5.5 v v ref can be either 3.3v (nominal) or 5v (nominal) v ref supply current active i ref 1 ma
smsc ds ? LPC47M15X page 192 rev. 08/02/2001 hardware monitoring block (t a = 0 o c ? 70 o c, hv cc = +3.3 10%) parameter symbol min typ max units comments temperature-to-digital converter characteristics internal temperature accuracy external diode sensor accuracy remote source current high level low level -3 -2 -5 -3 1 1 90 5.5 +3 +2 +5 +3 130 7.5 o c o c o c o c o c o c a a 0 0 c <= t a <= 70 0 c 40 0 c <= t a <= 70 0 c resolution -40 0 c <= t s <= 125 0 c 40 0 c <= t s <= 100 0 c resolution analog-to-digital converter characteristics total unadjusted error differential non-linearity power supply sensitivity total monitoring cycle time (cycle mode) conversion time (continuous mode) option 1 option 2 input resistance adc resolution tue dnl pss t c(cycle) t c(cts) t c(cts) 1 1 1.0 542.336 67.792 140 2 1.4 200 % lsb %/v sec msec msec k ? note 4 note 5 note 6 8 bits i m type input buffer (a0, vid0-vid4, xnor_in) low input level high input level v ili v ihi 2.1 0.8 hvcc+0.3 v v hvcc=3.3v i m type input buffer (sclk) low input level high input level hysteresis v ili v ihi v hys 2.1 500 0.8 hvcc+0.3 v v mv hvcc=3.3v
smsc ds ? LPC47M15X page 193 rev. 08/02/2001 hardware monitoring block (t a = 0 o c ? 70 o c, hv cc = +3.3 10%) parameter symbol min typ max units comments i m o3 type buffer (a0/nreset/ntherm/ xnor_out) low input level high input level low output level high output level nreset pulse width v ili v ihi v ol v oh t reset_pw 2.1 2.4 20 0.8 hvcc+0.3 0.4 hvcc+0.3 45 v v v v msec note 7 hvcc=3.3v i ol = +3.0 ma i oh = -3.0 ma hv cc = 3.3 v i m od3 type buffer (sda) low input level high input level hysteresis low output level high output level v ili v ihi v hys v ol v oh 2.1 500 0.8 hvcc+0.3 0.4 hvcc+0.3 v v mv v v hvcc=3.3v i ol = +3.0 ma open drain, hv cc = 3.3 v leakage current (all - digital) input high current input low current digital input capacitance ileak ih ileak il c in 10 -10 10 a a pf (note 1) v in = hv cc v in = 0v i ang type buffer ? analog inputs (dx+, dx-, +2.5v_in, +3.3v_in, +5v_in, +12v_in) refer to ?appendix a ? thermal diode parameters? and ?appendix b ? conversion tables?. hv cc supply current active see ?supply current? subsection in ?har dware monitoring block specifications? section above. note: voltages are measured from the local grou nd potential, unless ot herwise specified. typicals are at ta=25c and repres ent most likely parametric norm. the maximum allowable power dissipation at any temperature is pd = (tjmax - ta) / qja. timing specifications are tested at the ttl logic levels, vi l=0.4v for a falling edge and vi h=2.4v for a rising edge. tri-state output voltage is forced to 1.4v. note 1: all leakage currents are measured with all pins in high impedance. note 2: the minimum value given for v tr applies when v cc is active. when v cc is 0v, the minimum v tr is 0v.
smsc ds ? LPC47M15X page 194 rev. 08/02/2001 note 3: max i tri with v cc = 3.3v (nomial) is 5ma max i tri with v cc = 0v (nomial) is 250ua note 4: tue (total unadjusted error) includes offs et, gain and linearity errors of the adc. note 5: total monitoring cycle time includes all temperature conversions, all analog input voltage conversions. note 6: the cycle time for option 1 is 542.336ms (typical) if 128 measurement s are averaged for the remote diode temperature reading and 8 measurements are averaged for a ll voltage and the internal temperature reading. it is 67.792ms (typical) for option 2 if 16 measurements are averaged for the remo te diode temperature reading and a single measurement is taken for all voltage and the internal temperature reading (i.e., no averaging). note 7: v oh min and i oh does not apply to the nreset and ntherm open-drain functions. capacitance values for pins the input and output capacitance applies to both the super i/o block and the hardware monitoring block digital pins. capacitance t a = 25 o c; fc = 1mhz; v cc = 3.3v 10% limits parameter symbol min typ max unit test condition clock input capacitance c in 20 pf input capacitance c in 10 pf output capacitance c out 20 pf all pins except pin under test tied to ac ground note: the input capacitance of a port is measured at the connector pins.
smsc ds ? LPC47M15X page 195 rev. 08/02/2001 11. timing diagrams for the timing diagrams shown, the following capacitive loads are used on outputs. name capacitance total (pf) ser_irq 50 lad [3:0] 50 nldrq 50 ndir 240 nstep 240 nds0 240 nds1 240 pd[0:7] 240 nstrobe 240 nalf 240 j1x-y 50 j2x-y 50 kdat 240 kclk 240 mdat 240 mclk 240 midi_tx 50 fanx 50 ledx 50 txd1 50 txd2 50 sda 240
smsc ds ? LPC47M15X page 196 rev. 08/02/2001 t3 vcc all host a ccesses t2 t1 figure 12 ? power-up timing name description min typ max units t1 vcc slew from 2.7v to 0v 300 us t2 vcc slew from 0v to 2.7v 100 us t3 all host accesses after powerup (note 1) 125 500 us note 1: internal write-protection period after vcc passes 2.7 volts on power-up t1 t2 t2 clocki figure 13 ? input clock timing name description min typ max units t1 clock cycle time for 14.318mhz 69.84 ns t2 clock high time/low time for 14.318mhz 20 35 ns t1 clock cycle time for 32khz 31.25 us t2 clock high time/low time for 32khz 15.63 us clock rise time/fall time (not shown) 5 ns
smsc ds ? LPC47M15X page 197 rev. 08/02/2001 t1 t3 t2 pci_clk t5 t4 figure 14 ? pci clock timing name description min typ max units t1 period 30 33.3 nsec t2 high time 12 nsec t3 low time 12 nsec t4 rise time 3 nsec t5 fall time 3 nsec t1 npci_reset figure 15 ? reset timing name description min typ max units t1 npci_reset width 1 ms t3 t2 t1 clk output delay tri-state output figure 16 ? ouput timing meas urement conditions, lpc signals name description min typ max units t1 clk to signal valid delay ? bused signals 2 11 ns t2 float to active delay 2 11 ns t3 active to float delay 28 ns
smsc ds ? LPC47M15X page 198 rev. 08/02/2001 inputs valid t2 t1 clk input figure 17 ? input timing meas urement conditions, lpc signals name description min typ max units t1 input set up time to clk ? bused signals 7 ns t2 input hold time from clk 0 ns l1 l2 a ddress data tar sync=0110 l3 tar pci_clk nlframe lad[3:0] figure 18 ? i/o write note: l1=start; l2=cyctyp+dir; l3=sync of 0000 l1 l2 a ddress tar sync=0110 l3 data tar pci_clk nlframe lad[3:0] figure 19 ? i/o read note: l1=start; l2=cyctyp+dir; l3=sync of 0000 start msb lsb a ct pci_clk nldrq figure 20 ? dma request assertion through nldrq start c+d chl size tar sync=0101 l1 data tar pci_clk nlframe lad[3:0] figure 21 ? dma write (first byte) note: l1=sync of 0000
smsc ds ? LPC47M15X page 199 rev. 08/02/2001 start c+d chl size data tar sync=0101 l1 tar pci_clk nlframe lad[3:0] figure 22 ? dma read (first byte) note: l1=sync of 0000 t3 t1 t2 t4 t5 t6 t7 t8 ndir nstep nds0-1 ninde x nrdata nwdata t9 figure 23 ? floppy disk drive timing (at mode only) name description min typ max units t1 ndir set up to step low 4 x* t2 nstep active time low 24 x* t3 ndir hold time after nstep 96 x* t4 nstep cycle time 132 x* t5 nds0 & nds1 hold time from nstep low (note) 20 x* t6 nindex pulse width 2 x* t7 nrdata active time low 40 ns t8 nwdata write data width low .5 y* t9 nds0 & nds1, setup time ndir low (note) 0 ns *x specifies one mclk period an d y specifies one wclk period. mclk = 16 x data rate (at 500 kb/s mclk = 8 mhz) wclk = 2 x data rate (at 500 kb/s wclk = 1 mhz) note: the ds0 &ds1 setup and hold times must be met by software.
smsc ds ? LPC47M15X page 200 rev. 08/02/2001 t9 t8 t7 t6 t4 t5 t3 t2 t1 nwrite pd<7:0> ndatastb naddrstb nwait figure 24 ? epp 1.9 data or address write cycle name description min typ max units t1 nwait asserted to nwrite asserted (note 1) 60 185 ns t2 nwait asserted to nwrite change (note 1) 60 185 ns t3 nwait asserted to pdata invalid (note 1) 0 ns t4 pdata valid to command asserted 10 ns t5 nwrite to command asserted 5 35 ns t6 nwait asserted to command asserted (note 1) 60 210 ns t7 nwait deasserted to command deasserted (note 1) 60 190 ns t8 command asserted to nwait deasserted 0 10 us t9 command deasserted to nwait asserted 0 ns note 1: nwait must be filtered to compensate for ringing on the parallel bus cable. nwait is considered to have settled after it does not transition for a minimum of 50 nsec.
smsc ds ? LPC47M15X page 201 rev. 08/02/2001 t12 t11 t10 t9 t7 t8 t6 t5 t4 t3 t2 t1 nwrite pd<7:0> ndatastb naddrstb nwait figure 25 ? epp 1.9 data or address read cycle name description min typ max units t1 nwait asserted to nwrite deasserted 0 185 ns t2 nwait asserted to nwrite modified (notes 1,2) 60 190 ns t3 nwait asserted to pdata hi-z (note 1) 60 180 ns t4 command asserted to pdata valid 0 ns t5 command deasserted to pdata hi-z 0 ns t6 nwait asserted to pdata driven (note 1) 60 190 ns t7 pdata hi-z to command asserted 0 30 ns t8 nwrite deasserted to command 1 ns t9 nwait asserted to command asserted 0 195 ns t10 nwait deasserted to command deasserted (note 1) 60 180 ns t11 pdata valid to nwait deasserted 0 ns t12 pdata hi-z to nwait asserted 0 s note 1: nwait is considered to have settled after it does not transition for a minimum of 50 ns. note 2: when not executing a write cycle, epp nwrite is inactive high.
smsc ds ? LPC47M15X page 202 rev. 08/02/2001 t5 t4 t3 t2 t1 nwrite pd<7:0> ndatastb naddrstb nwait figure 26 ? epp 1.7 data or address write cycle name description min typ max units t1 command deasserted to nwrite change 0 40 ns t2 command deasserted to pdata invalid 50 ns t3 pdata valid to command asserted 10 35 ns t4 nwrite to command 5 35 ns t5 command deasserted to nwait deasserted 0 ns t3 t2 t1 nwrite pd<7:0> ndatastb naddrstb nwait figure 27 ? epp 1.7 data or address read cycle name description min typ max units t1 command asserted to pdata valid 0 ns t2 command deasserted to pdata hi-z 0 ns t3 command deasserted to nwait deasserted 0 ns
smsc ds ? LPC47M15X page 203 rev. 08/02/2001 ecp parallel port timing parallel port fifo (mode 101) the standard parallel port is run at or near the peak 500kbytes/sec allowed in the forward direction using dma. the state machine does not examine nack and begins the next transfer based on busy. refer to figure 28. ecp parallel port timing the timing is designed to allow operation at approximately 2. 0 mbytes/sec over a 15ft cable. if a shorter cable is used then the bandwidth will increase. forward-idle when the host has no data to send it keeps hostclk (nstr obe) high and the peripheral will leave periphclk (busy) low. forward data transfer phase the interface transfers data and commands from the host to the peripheral using an interlocked periphack and hostclk. the peripheral may indicate its desire to send data to the host by asserting nperiphrequest. the forward data transfer phase may be entered from the forward-idle phase. while in the forward phase the peripheral may asynchronously assert the nperiphrequest (nfault) to request that the channel be reversed. when the peripheral is not busy it sets periphack (busy) low. the host then sets hostclk (nstrobe) low when it is prepared to send data. the data must be stable for the specified setup time prior to the falling edge of hostclk. the peripheral then sets periphack (busy) high to acknowledge the handshake. the host then sets hostclk (nstrobe) high. the peripheral then accepts the data and sets periphack (busy) low, completing the transfer. this sequence is shown in figure 29. the timing is designed to provide 3 cable round-trip times for data setup if data is driven simultaneously with hostclk (nstrobe). reverse-idle phase the peripheral has no data to send and keeps periphclk high. the host is idle and keeps hostack low. reverse data transfer phase the interface transfers data and commands from the peripheral to the host using an interlocked hostack and periphclk. the reverse data transfer phase may be entered from the reverse-idle phase. after the previous byte has beed accepted the host sets hostack (nalf) low. the peripheral then sets periphclk (nack) low when it has data to send. the data must be stable for the specified setup time prior to the falling edge of periphclk. when the host is ready to accept a byte it sets hostack (nalf) high to acknowledge the handshake. the peripheral then sets periphclk (nack) high. after the host has accepted the data it sets hostack (nalf) low, completing the transfer. this sequence is shown in figure 30. output drivers to facilitate higher performance data tr ansfer, the use of balanced cmos active drivers for critical signals (data, hostack, hostclk, periphack, periphclk) are used in ecp mode. because the use of ac tive drivers can present compatibility problems in compatible mode (the control signals, by tradition, are specified as open-drain), the drivers are dynamically changed from open-drain to push-pull. the timing for the dynamic driver change is specified in then ieee 1284 extended capabilities port protocol and isa in terface standard, re v. 1.14, july 14, 1993, available from microsoft. the dynamic driver change must be implemented properly to prevent glitching the outputs.
smsc ds ? LPC47M15X page 204 rev. 08/02/2001 figure 28 ? parallel port fifo timing name description min typ max units t1 pdata valid to nstrobe active 600 ns t2 nstrobe active pulse width 600 ns t3 pdata hold from nstrobe inactive (note 1) 450 ns t4 nstrobe active to busy active 500 ns t5 busy inactive to nstrobe active 680 ns t6 busy inactive to pdata invalid (note 1) 80 ns note 1: the data is held until busy goes inactive or for time t3, whichever is longer. this only applies if another data transfer is pending. if no other data transfer is pending, the data is held indefinitely. t3 t6 t1 t2 t5 t4 pd<7:0> nstrobe busy
smsc ds ? LPC47M15X page 205 rev. 08/02/2001 t3 t4 t1 t2 t7 t8 t6 t5 t6 nalf pd<7:0> busy nstrobe figure 29 ? ecp parallel port forward timing name description min typ max units t1 nalf valid to nstrobe asserted 0 60 ns t2 pdata valid to nstrobe asserted 0 60 ns t3 busy deasserted to nalf changed (notes 1,2) 80 180 ns t4 busy deasserted to pdata changed (notes 1,2) 80 180 ns t5 nstrobe asserted to busy asserted 0 ns t6 nstrobe deasserted to busy deasserted 0 ns t7 busy deasserted to nstrobe asserted (notes 1,2) 80 200 ns t8 busy asserted to nstrobe deasserted (note 2) 80 180 ns note 1: maximum value only applies if there is data in the fifo waiting to be written out. note 2: busy is not considered asserted or deasserted until it is stable for a minimum of 75 to 130 ns.
smsc ds ? LPC47M15X page 206 rev. 08/02/2001 t2 t1 t5 t6 t4 t3 t4 pd<7:0> nack nalf figure 30 ? ecp parallel port reverse timing name description min typ max units t1 pdata valid to nack asserted 0 ns t2 nalf deasserted to pdata changed 0 ns t3 nack asserted to nalf deasserted (notes 1,2) 80 200 ns t4 nack deasserted to nalf asserted (note 2) 80 200 ns t5 nalf asserted to nack asserted 0 ns t6 nalf deasserted to nack deasserted 0 ns note 1: maximum value only applies if there is room in the fifo and terminal count has not been received. ecp can stall by keeping nalf low. note 2: nack is not considered asserted or deasserted until it is stable for a minimum of 75 to 130 ns.
smsc ds ? LPC47M15X page 207 rev. 08/02/2001 t1 t2 t2 t1 01010 011011 data irrx n irrx t1 t1 t1 t1 t1 t1 t1 t2 t2 t2 t2 t2 t2 t2 pa rame ter min ty p m ax units 1. 4 1. 4 1. 4 1. 4 1. 4 1. 4 1. 4 2. 71 3. 69 5. 53 11.07 22.13 44.27 88.55 s s s s s s s s s s s s s s pulse w idt h at 1 15kba ud pul se wid th at 57. 6kba ud pul se wid th at 38. 4kba ud pul se wid th at 19. 2kba ud pu lse wi dt h a t 9. 6kba ud pu lse wi dt h a t 4. 8kba ud pu lse wi dt h a t 2. 4kba ud bit t ime at 1 15kba ud bit time at 57.6kbaud bit time at 38.4kbaud bit time at 19.2kbaud bi t ti me a t 9. 6kba ud bi t ti me a t 4. 8kba ud bi t ti me a t 2. 4kba ud 1. 6 3. 22 4. 8 9. 7 19. 5 39 78 8. 68 17. 4 26 52 104 208 416 no te s: 1. recei ve pu lse det ect ion c ri te ria: a re ceived p ulse is consi dered d et ecte d if t he receive d p ulse is a mini mum o f 1. 41 s. 2. ir rx: l5, crf 1 bit 0 = 1 ni rrx: l5 , crf 1 bi t 0 = 0 ( def aul t ) figure 31 ? irda receive timing
smsc ds ? LPC47M15X page 208 rev. 08/02/2001 t1 t1 t1 t1 t1 t1 t1 t2 t2 t2 t2 t2 t2 t2 parameter mi n 1.41 1.41 1.41 1.41 1.41 1.41 1.41 ma x 2.71 3.69 5.53 11.07 22.13 44.27 88.55 units s s s s s s s s s s s s s s pulse width at 115kbaud pulse widt h at 57. 6kbaud pulse widt h at 38. 4kbaud pulse widt h at 19. 2kbaud pulse widt h at 9. 6kbaud pulse widt h at 4. 8kbaud pulse widt h at 2. 4kbaud bit t ime at 115kbaud b it tim e at 57. 6kbaud b it tim e at 38. 4kbaud b it tim e at 19. 2kbaud bit tim e at 9.6kbaud bit tim e at 4.8kbaud bit tim e at 2.4kbaud typ 1.6 3.22 4.8 9.7 19.5 39 78 8.68 17.4 26 52 104 208 416 t1 t2 t2 t1 0 10 1 0 0 11 0 11 dat a irtx n i rt x notes: 1. irda @ 115k i s hpsir com pati ble. irda @ 2400 wi ll al low compatibilit y with hp95lx and 48sx. 2. irt x: l5, crf 1 bit 1 = 1 (default) nirtx: l5, crf1 bit 1 = 0 figure 32 ? irda transmit timing
smsc ds ? LPC47M15X page 209 rev. 08/02/2001 t1 t2 t3 t4 t5 t6 pa ramet er min typ max units 0.8 0.8 0.8 0.8 1.2 1.2 1.2 1.2 s s s s s s m odu lated out put bit t ime off bit t ime m odu l ated outp ut " on" m odu lated out put " off" m odu l ated outp ut " on" m odu lated out put " off" 1 1 1 1 note s: 1 . irrx: l 5, crf 1 bit 0 = 1 n irrx : l5 , crf 1 b i t 0 = 0 (de faul t) m irrx, nmi rrx are the mod ulate d ou t p uts t1 t2 t3 t4 t5 t6 01010011011 dat a irrx n irrx m irrx nm irrx figure 33 ? amplitude shift keyed ir receive timing
smsc ds ? LPC47M15X page 210 rev. 08/02/2001 t1 t2 t3 t4 t5 t6 parameter min typ max units 0.8 0.8 0.8 0.8 1.2 1.2 1.2 1.2 s s s s s s m odu lated out put b i t t ime off bit t ime m odu lated outp ut " on" m odu lated outp ut " off" m odu lated outp ut " on" m odu lated outp ut " off" 1 1 1 1 note s: 1 . irt x: l5 , crf 1 bit 1 = 1 (def ault) ni rtx: l 5, crf 1 bit 1 = 0 mirt x , nm irt x a re the mod ulate d ou tpu ts t1 t2 t3 t4 t5 t6 01010 011011 dat a irt x n irt x mir t x nmirtx figure 34 ? amplitude shift keyed ir transmit timing
smsc ds ? LPC47M15X page 211 rev. 08/02/2001 t2 t1 pci_clk ser_irq figure 35 ? setup and hold time name description min typ max units t1 ser_irq setup time to pci_clk rising 7 nsec t2 ser_irq hold time to pci_clk rising 0 nsec data (5-8 bits) t1 data txd1, 2 start parity stop (1-2 bits) figure 36 ? serial port data name description min typ max units t1 serial port data bit time t br 1 nsec note 1: t br is 1/baud rate. the baud rate is programmed through the divisor latch registers. baud rates have percentage errors indicated in the ?baud rate? table in the ?serial port? section.
smsc ds ? LPC47M15X page 212 rev. 08/02/2001 j1x, j1y, j2x, j2y 2 3 vref t1 vref +/- 5% figure 37 ? joystick position signal name description min typ max units t1 rise time to 2/3 vref 20 sec j1b1, j1b2, j2b1, j2b2 t1 t2 90% 10% 90% 10% figure 38 ? joystick button signal name description min typ max units t1, t2 button fall/rise time 10 sec
smsc ds ? LPC47M15X page 213 rev. 08/02/2001 kclk/ mclk kdat/ mdat start bit bit 0 bit 7 clk 1 clk 2 clk 9 clk 10 t1 t6 t4 t3 clk 11 t5 parity bit stop bit t2 figure 39 ? keyboard/mouse receive/send data timing name description min typ max units t1 time from data transition to falling edge of clock (receive) 5 25 sec t2 time from rising edge of clock to data transition (receive) 5 t4-5 sec t3 duration of clock inactive (receive/send) 30 50 sec t4 duration of clock active (receive/send) 30 50 sec t5 time to keyboard inhibit after clock 11 to ensure the keyboard does not start another transmission (receive) >0 50 sec t6 time from inactive to active clock transition, used to time when the auxiliary device samples data (send) 5 25 sec data data t1 data midi_tx idle (no data) idle (no data) stop bit start bit figure 40 ? midi data byte name description min typ max units t1 midi data bit time 31.7 32 32.3 sec note: the midi bit clock is 31.25khz +/- 1%
smsc ds ? LPC47M15X page 214 rev. 08/02/2001 figure 41 ? fan output timing name description min typ max units t1 pwm period (note 1) 0.021 25.5 msec t2 pwm high time (note 2) 0.00033 25.1 msec note 1: the period is 1/f out ,where f out is programmed through the fanx and fan control registers. the tolerance on f out is +/- 2%. note 2: when bit 0 of the fanx registers is 0, then the duty cy cle is programmed through bits[6:1] of these registers. if bits[6:1] = ?000000? then the fanx pin is low. the duty cycle is programmable through bits[6:1] to be between 1.56% and 98.44%. when bit 0 is 1, the fanx pin is high. t3 t1 t2 fan_tachx figure 42 ? fan tachometer intput timing name description min typ max units t1 pulse time (1/2 revolution time=30/rpm) 4t tach 1 sec t2 pulse high time 3t tach 1 sec t3 pulse low time t tach sec note 1: t tach is the clock used for the tachometer counter. it is 30.52 * dvsr, where the divisor (dvsr) is programmed in the fan control register. t1 t2 fanx
smsc ds ? LPC47M15X page 215 rev. 08/02/2001 t2 t1 ledx figure 43 ? led output timing name description min typ max units t1 period 1 2 sec t2 blink on time 0 0.5 1 sec note 1: the blink rate is programmed through bits[1:0] in ledx register. when bits[1:0]=00, led is off. bits[1:0]=01 indicates led blink at 1hz rate with a 50% duty cycle (0.5 sec on, 0.5 sec off). bits[1:0]=10 indicates led blink at ? hz rate with a 25% duty cycle (0.5 sec on, 1.5 sec off). when bits[1:0]=11, led is on.
smsc ds ? LPC47M15X page 216 rev. 08/02/2001 smbus timing p t buf t r t hd;sta p s s t hd;sta t low t hd;dat t high t f t su;dat t su;sta t su;sto sclk sda figure 44 ? smbus timing symbol parameter limits units comments min max f smb smb operating frequency 10 400 khz note 1 t sp spike suppression 50 ns note 2 t buf bus free time between stop and start condition 1.3 s t hd : sta hold time after (repeated) start condition. after this period, the first clock is generated. 0.6 s t su : sta repeated start condition setup time 0.6 s t su : sto stop condition setup time 0.6 s t hd : dat data hold time 0.3 0.9 s t su : dat data setup time 100 ns note 3 t low clock low period 1.3 s t high clock high period 0.6 s t f clock/data fall time 20+0.1c b 300 ns t r clock/data rise time 20+0.1c b 300 ns c b capacitive load for each bus line 400 pf note 1: the smbus timing (e.g., max clock frequency of 400khz) specified exceeds that specified in the system management bus specification, rev 1.1. this corresponds to the maximum clock frequency for fast mode devices on the i 2 c bus. see ?the i 2 c bus specification,? version 2.0, dec. 1998. note 2: at 400khz, spikes of a maximum pulse width of 50ns must be suppressed by the input filter. note 3: if using 100 khz clock frequency, the next data bit output to the sda line will be 1250 ns (1000 ns (t r max) + 250 ns (t su : dat min) @ 100 khz) before the sclk line is released.
smsc ds ? LPC47M15X page 217 rev. 08/02/2001 12. package outline figure 45 ? 128 pin qfp package outline, 3.9mm footprint min nominal max remarks a ~ ~ 3.4 overall packa g e hei g ht a1 0.05 ~ 0.5 standof f a2 2.55 ~ 3.05 bod y thickness d 23.70 ~ 24.10 x s p an d1 19.90 ~ 20.10 x bod y size e 17.70 ~ 18.10 y s p an e1 13.90 ~ 14.10 y bod y size h 0.09 ~ 0.20 lead frame thickness l 0.73 0.88 1.03 lead foot len g th l1 ~ 1.95 ~ lead len g th e 0.50 basic lead pitch 0 o ~ 7 o lead foot an g le w 0.10 ~ 0.30 lead width r1 0.13 ~ ~ lead shoulder radius r2 0.13 ~ 0.30 lead foot radius ccc ~ ~ 0.08 co p lanarit y notes: 1 controlling unit: millimeter. 2 tolerance on the position of the leads is 0.04 mm maximum. 3 package body dimensions d1 and e1 do not include the mold protrusion. maximum mold protrusion is 0.25 mm. 4 dimension for foot length l measured at the gauge plane 0.25 mm above the seating plane. 5 details of pin 1 identifier are optional but must be located within the zone indicated.
smsc ds ? LPC47M15X page 218 rev. 08/02/2001 13. appendix a ? thermal diode parameters the pentium ii and pentium iii processors incorporate an on-die diode that may be used to monitor the die temperature (junction temperature). table a1 provides the diode parameters. table 77 ? thermal diode parameters symbol min typ max unit notes i 2 forward bias 5 5 500 300 ua ua 1 6 n_ideality 1.0000 1.0057 1.0065 1.0080 1.0173 1.0125 2, 3, 4 2, 3, 5, 6 notes: 1. intel does not support or recommend operat ion of the thermal diode under reverse bias. 2. at room temperature with a forward bias of 630 mv. 3. n_ideality is the diode ideality factor param eter, as represented by the diode equation: i 2 =i 1 (e^ (vd*q)/(nkt) - 1) where i 1 is saturation current vd is change in vbe q is the electron charge k is the boltzmann?s constant t is the absolute temperature in o k 4. this specification applies to the pentium ii processor and pentium iii processor (cpuid=067xh) for the sc242 at 450mhz to 1.13ghz. 5. this specification applies to the pentium iii processor (cpuid=068xh) for the sc242 at 450mhz to 1.13ghz. 6. this specification applies to the pentium iii processor for the pga370 socket at 500mhz to 1ghz.
smsc ds ? LPC47M15X page 219 rev. 08/02/2001 14. appendix b ? adc voltage conversion table 78 ? analog-to-digital conversions for hardware monitoring block input voltage a/d output 12 v in 5 v in hv cc /3.3 v in 2.5 v in 1.8 v in 1.5 v in v ccp_in decimal binary <0.062 <0.026 <0.0172 <0.013 <0.009 <0.008 <0.012 0 0000 0000 0.062?0.125 0.026?0.052 0.017?0.034 0.013?0.026 0.009- 0.019 0.008-0.016 0.012?0.023 1 0000 0001 0.125?0.188 0.052?0.078 0.034?0.052 0.026?0.039 0.019- 0.028 0.016-0.023 0.023?0.035 2 0000 0010 0.188?0.250 0.078?0.104 0.052?0.069 0.039?0.052 0.028- 0.038 0.023-0.031 0.035?0.047 3 0000 0011 0.250?0.313 0.104?0.130 0.069?0.086 0.052?0.065 0.038- 0.047 0.031-0.039 0.047?0.058 4 0000 0100 0.313?0.375 0.130?0.156 0.086?0.103 0.065?0.078 0.047- 0.056 0.039-0.047 0.058?0.070 5 0000 0101 0.375?0.438 0.156?0.182 0.103?0.120 0.078?0.091 0.056- 0.066 0.047-0.055 0.070?0.082 6 0000 0110 0.438?0.500 0.182?0.208 0.120?0.138 0.091?0.104 0.066- 0.075 0.055-0.063 0.082?0.093 7 0000 0111 0.500?0.563 0.208?0.234 0.138?0.155 0.104?0.117 0.075- 0.084 0.063-0.070 0.093?0.105 8 0000 1000 ? ? ? ? ? ? ? ? ? 4.000?4.063 1.666?1.692 1.100?1.117 0.833?0.846 0.600-0.609 0.500-0.508 0.749?0.761 64 (1/4 scale) 0100 0000 ? ? ? ? ? ? ? ? ? 8.000?8.063 3.330?3.560 2.200?2.217 1.667?1.680 1.200-1.209 1.000-1.008 1.499?1.511 128 (1/2 scale) 1000 0000 ? ? ? ? ? ? ? ? ? 12.000?12.063 5.000?5.026 3.300?3.317 2.500?2.513 1.800-1.809 1.500-1.508 2.249?2.261 192 (3/4 scale) 1100 0000 ? ? ? ? ? ? ? ? ? 15.312?15.375 6.380?6.406 4.210?4.230 3.190?3.203 2.297- 2.306 1.914-1.922 2.869?2.881 245 1111 0101 15.375?15.437 6.406?6.432 4.230?4.245 3.203?3.216 2.306- 2.316 1.922-1.930 2.881?2.893 246 1111 0110 15.437?15.500 6.432?6.458 4.245?4.263 3.216?3.229 2.316- 2.325 1.930-1.938 2.893?2.905 247 1111 0111 15.500?15.563 6.458?6.484 4.263?4.280 3.229?3.242 2.325- 2.334 1.938-1.945 2.905?2.916 248 1111 1000 15.625?15.625 6.484?6.510 4.280?4.300 3.242?3.255 2.334- 2.344 1.945-1.953 2.916?2.928 249 1111 1001 15.625?15.688 6.510?6.536 4.300?4.314 3.255?3.268 2.344- 2.353 1.953-1.961 2.928?2.940 250 1111 1010 15.688?15.750 6.536?6.562 4.314?4.330 3.268?3.281 2.353- 2.363 1.961-1.969 2.940?2.951 251 1111 1011 15.750?15.812 6.562?6.588 4.331?4.348 3.281?3.294 2.363- 2.372 1.969-1.977 2.951?2.964 252 1111 1100 15.812?15.875 6.588?6.615 4.348?4.366 3.294?3.307 2.372- 2.381 1.977-1.984 2.964?2.975 253 1111 1101 15.875?15.938 6.615?6.640 4.366?4.383 3.307?3.320 2.381- 2.391 1.984-1.992 2.975?2.987 254 1111 1110 >15.938 >6.640 >4.383 >3.320 >2.391 >1.992 >2.988 255 1111 1111
smsc ds ? LPC47M15X page 220 rev. 08/02/2001 15. appendix c - test mode the LPC47M15X provides board test capability through the implementation of two xnor chains. one chain is dedicated to the super i/o portion of the chip (pins 1 ? 100) and the second chain is dedicated solely to the hardware monitoring block (pins 101 ? 128). xnor-chain test mode xnor-chain test structure allows users to confirm that all pins are in contact with the motherboard during assembly and test operations. see figure 46 below. when the chip is in the xnor chain test mode, setting the state of any of the input pins to the opposite of its current state will cause the output of the chain to toggle. the xnor-chain test structure must be activated to perform these tests. when the xnor-chain is activated, the LPC47M15X pin functions are disconnected from the device pins, which all become input pins except for one output pin at the end of xnor-chain. the tests that are performed when the xnor-chain test structure is activated require the board-level test hardware to control the device pins and observe the results at the xnor-chain output pin. figure 46 ? xnor-chain test structure 15.1 super i/o block 15.1.1 board test mode board test mode can be entered as follows: on the rising (deasserting) edge of npci_reset , drive nlframe low and drive lad[0] low. exit board test mode as follows: on the rising (deasserting) edge of npci_reset , drive either nlframe or lad[0] high. see the ?xnor-chain test mode? section above for a description of this board test mode. the npci_reset pin is not included in the xnor-chain. the xnor-chain output pin# is 85, txd1. see the following subsections for more details. pin list of super i/o xnor chain pins 1 to 100 on the chip are inputs to the first xnor chain, with the exception of the following: 1) vcc (pins 53, 65, & 93), vtr (pin 18), and vref (pin 44). 2) vss (pins 7, 31, 60, & 76) and avss (pin 40). 3) txd1 (pin 85) this is the chain output. 4) npci_reset (pin 26). i/o#1 i/o#2 i/o#3 i/o#n xnor out
smsc ds ? LPC47M15X page 221 rev. 08/02/2001 to put the chip in the first xnor chain test mode, tie lad0 (pin 20) and nlframe (pin 24) low. then toggle npci_reset (pin 26) from a low to a high state. once the ch ip is put into xnor chain test mode, lad0 (pin 20) and nlframe (pin 24) become part of the chain. to exit the first xnor chain test mode tie lad0 (pin 20) or nlframe (pin 24) high. then toggle npci_reset (pin 26) from a low to a high state. a vcc por will also cause the xnor chain test mode to be exited. to verify the test mode has been exited, observe the output at txd1 (pin 85). toggling any of the input pins in the chain should not cause its state to change. setup of super i/o xnor chain warning: ensure power supply is off during setup. 1) connect vss (pins 7, 31, 60, & 76) and avss (pin 40) to ground. 2) connect vcc (pins 53, 65, & 93), vtr (pin 18), and vref (pin 44) to vcc (3.3v). 3) connect an oscilloscope or voltmeter to txd1 (pin 85). 4) all other pins should be tied to ground. testing 1) turn power on. 2) with lad0 (pin 20) and nlframe (pin 24), low, bri ng npci_reset (pin 26) high. the chip is now in xnor chain test mode. at this point, all inputs to the first xnor chain are low. the output, on txd1 (pin 85), should also be low. refer to initial config on truth table 1. 3) bring pin 100 high. the output on txd1 (pin 85) should go high. refer to step one on truth table 1. 4) in descending pin order, bring each input high. the output should switch states each time an input is toggled. continue until all inputs are high. the output on txd1 should now be low. refer to end config on truth table 1. 5) the current state of the chip is now represented by initial config in truth table 2. 6) each input should now be brought low, starting at pin one and continuing in ascending order. continue until all inputs are low. the output on txd1 should now be low. refer to truth table 2. 7) to exit test mode, tie lad0 (pin 20) or nlframe (pin 24) high, and toggle npci_reset from a low to a high state. truth table 1 - toggling inputs in descending order pin 100 pin 99 pin 98 pin 97 pin 96 pin ... pin 1 output pin 85 initial config l l l l l l l l step 1 h l l l l l l h step 2 h h l l l l l l step 3 h h h l l l l h step 4 h h h h l l l l step 5 h h h h h l l h ? ? ? ? ? ? ? ? ? step n h h h h h h l h end config h h h h h h h l
smsc ds ? LPC47M15X page 222 rev. 08/02/2001 truth table 2 - toggling inputs in ascending order pin 1 pin 2 pin 3 pin 4 pin 5 pin ... pin 100 output pin 85 initial config h h h h h h h l step 1 l h h h h h h h step 2 l l h h h h h l step 3 l l l h h h h h step 4 l l l l h h h l step 5 l l l l l h h h ? ? ? ? ? ? ? ? step n l l l l l l h h end config l l l l l l l l 15.2 hardware moni toring block 15.2.1 board test mode board test mode for the hardware monitor block is implemented as an xnor-chain as described in the subsection below. the xnor chain for the hardware monitor block is self-contained within the hardware monitor block. the xnor chain for the rest of the chip is separate from the xnor chain for the hardware monitor block. board test mode for the hardware monitoring block can be entered by programming a ?1? to the xnor_in pin at power-up. to exit the test mode, the xnor_in pin should be tied to ?0? on the subsequent power up. 15.2.2 xnor-chain test mode the tests that are performed when the xnor-chain test structure is activated require the board-level test hardware to control the device pins and observe the results at the xnor-chain output pin. the xnor-chain output is on a0/nreset/ntherm/xnor_out pin. hvcc, gnd and all th e analog pins are not used as inputs for xnor-chain test. testing 1) program a ?1? on xnor_in pin. turn power on. the hardware monitor block is now in xnor chain test mode. at this point, all inputs to the xnor chain are low. the output on a0/nreset/ntherm/xnor_out will also be high. refer to initial config on truth table 3. 2) bring vid4 pin high. the output on a0/nreset/nther m/xnor_out will go low. refer to step one on truth table 3. 3) in descending pin order, bring each input high. the output will switch states each time an input is toggled. continue until all inputs are high. the output on a0/nreset/ntherm/xnor_out will now be low. refer to end config on truth table 3. 4) the current state of the hardware monitor block is now represented by initial config in truth table 4. 5) each input should now be brought low, starting at pin one and continuing in ascending order. continue until all inputs are low. the output on a0/nreset/ntherm/xnor _out will now be high. refer to truth table 4. 6) to exit test mode, tie the xnor_in pin low, and power down the hardware monitor block. the hardware monitor block will not be in test mode on the subsequent power-up.
smsc ds ? LPC47M15X page 223 rev. 08/02/2001 truth table 3 - toggling inputs in descending order vid4 vid3 vid2 vid1 vid0 sclk sda xnor_out initial config l l l l l l l h step 1 h l l l l l l l step 2 h h l l l l l h step 3 h h h l l l l l step 4 h h h h l l l h step 5 h h h h h l l l step 6 h h h h h h l h end config h h h h h h h l truth table 4 - toggling inputs in ascending order sda sclk vid0 vid1 vid2 vid3 vid4 xnor_out initial config h h h h h h h l step 1 l h h h h h h h step 2 l l h h h h h l step 3 l l l h h h h h step 4 l l l l h h h l step 5 l l l l l h h h step 6 l l l l l l h l end config l l l l l l l h
smsc ds ? LPC47M15X page 224 rev. 08/02/2001 16. reference documents 1) smsc consumer infrared communications controller (circc) v1.x 2) ieee 1284 extended capabilities port protocol and isa standard, rev. 1.14, july 14, 1993. 3) hardware description of the 8042, intel 8 bit embedded controller handbook. 4) pci bus power management interface specif ication, rev. 1.0, draft, march 18, 1997. 5) low pin count (lpc) interface specification, revision 1.0, september 29, 1997, intel document. 6) metalious acpi/manageability spec ification, v1.0, aril 30, 1999 7) advanced configuration and power interface specification, v 1.0 8) smsc application note, an 8-8: using the enhanced keyboard and mouse wakeup feature in smsc super i/o parts. 9) smsc application note, an 8-20: using the hardware monitor feature in smsc super i/o devices. 10) smsc application note, an 9-3: application cons iderations when using the powerdown feature of smsc floppy disk controllers.


▲Up To Search▲   

 
Price & Availability of LPC47M15X

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X